Turn the Case Study into a Content Management System
Designing and Creating the Table
The first step is to create the table that will contain the page data. What is the information you need in this file? There is the obvious information such as
and other information you might want to keep:
- User who created the article
- Date article was created
- User who last modified the article
- Last date the article was modified
You also need a primary key so that you can select which article you want to display. Remember that the primary key cannot change and should be unique. Therefore you do not want to use the title as the key. Use an auto-increment integer key as you have in the other file.
This example is for a freeform page, but depending on your application, you could add additional fields that you could then place in particular places on the page. For instance, if you want all the articles to start with a picture and a short introduction and be followed by a list of references, you could add fields for each of those in your table.
You might also want to put your articles into different categories the way that the lots are in the Case Study. ...