Site Home page of the different sections, some are pictures, some contain the title plus introduction, some only the title, these are specifically built data table to store it, if so, it seems that these different plates can not be built in a data table. For example, the picture plate needs to store the title, the image URL, the article ID, and others may not need to store the image URL, so that different plates need different fields.
May be a bit messy, just want to ask the next page of the different elements in the background is how to store?
Reply content:
Site Home page of the different sections, some are pictures, some contain the title plus introduction, some only the title, these are specifically built data table to store it, if so, it seems that these different plates can not be built in a data table. For example, the picture plate needs to store the title, the image URL, the article ID, and others may not need to store the image URL, so that different plates need different fields.
May be a bit messy, just want to ask the next page of the different elements in the background is how to store?
A table would be fine. Why do you want multiple tables ...
Do you still have more than one interface in the background to send articles? (Hair section 1 of the article Interface, Hair section 100 of the article interface?) )
A table to save the title, picture, article, section location, not OK?
In the same vein, when publishing an article, choose which section is on the line.
Like this idea, you know.
A table is enough, use a field to distinguish between different plates.
When the page is displayed, it is divided into several arrays by the plate, and the template is plugged in.
A table, you said do not need to save the image URL, the field is empty on the line
In principle, we can. From the extreme: you can build a table with a piece of news, a picture to build a table. Then slowly to the normal to push: the same kind of news a table. And then push: not the same kind of news can also use a table, only need to add a field to indicate which category each belongs to. Wait a minute. There is no accurate answer, need to take into account the convenience of understanding and adding and removing the efficiency of these aspects.
SQL storage tree structure enables unlimited classification
CREATE TABLE `typecho_contents` ( `cid` int(10) unsigned NOT NULL auto_increment, `title` varchar(200) default NULL, `slug` varchar(200) default NULL, `created` int(10) unsigned default '0', `modified` int(10) unsigned default '0', `text` text, `order` int(10) unsigned default '0', `authorId` int(10) unsigned default '0', `template` varchar(32) default NULL, `type` varchar(16) default 'post', `status` varchar(16) default 'publish', `password` varchar(32) default NULL, `commentsNum` int(10) unsigned default '0', `allowComment` char(1) default '0', `allowPing` char(1) default '0', `allowFeed` char(1) default '0', `parent` int(10) unsigned default '0', PRIMARY KEY (`cid`), UNIQUE KEY `slug` (`slug`), KEY `created` (`created`)) ENGINE=MyISAM DEFAULT CHARSET=utf8;
Just a simple table for many extensions