If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > General > Database Concepts & Design > designing a small CMS, need help?

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 04-05-06, 05:10
demiurgen demiurgen is offline
Registered User
 
Join Date: Apr 2006
Location: Norway
Posts: 26
designing a small CMS, need help?

i am going to make a tiny little CMS for a site with about 5 or 6 pages.

but how should i design the structure?
what should the tables contain?

is it ok to make it like this:
a page is called prices, so i make a table called prices.
on that page i have a h1 tag and 3 p tags, so i make 1 column called h1 and 3 columns called p1, p2 and p3
and i have i picture to so i make another column called img

is this a way to go?
how is a pro CMS designed??
Reply With Quote
  #2 (permalink)  
Old 04-05-06, 10:57
rajiravi rajiravi is offline
Registered User
 
Join Date: Apr 2004
Location: Toronto, Canada
Posts: 249
Please read a little bit of relational theory

Hi,

Please read up a bit on some fundamentals of relational databases.

It is not possible to understand your problem from what you have described.

Ravi
Reply With Quote
  #3 (permalink)  
Old 04-06-06, 02:51
demiurgen demiurgen is offline
Registered User
 
Join Date: Apr 2006
Location: Norway
Posts: 26
i am just wondering how to design the ER model for a CMS-based DB.
how many entities? which entities? how many attributes per entity? which attributes?
basically, what should i include in the DB??
does anybody know about a tutorial for a CMS-based DB??
Reply With Quote
  #4 (permalink)  
Old 04-06-06, 05:43
andrewst andrewst is offline
Moderator.
 
Join Date: Sep 2002
Location: UK
Posts: 5,171
Actually, I'm not sure what you mean by CMS. My first thought was "Code Management System", but looking at your examples of prices and pictures that seems unlikely. "Contact Management System" perhaps? Or did you really mean CRM (Customer Relationship Management)?

Anyway, there's a kick-start data model for Contact Management here on Database Answers, and if that isn't what you want there are 200 other models on that site to choose from.
__________________
Tony Andrews
http://tinyurl.com/tonyandrews
Reply With Quote
  #5 (permalink)  
Old 04-06-06, 06:58
demiurgen demiurgen is offline
Registered User
 
Join Date: Apr 2006
Location: Norway
Posts: 26
by CMS i mean Content Management System

i may be wrong about the name...

i am trying to make a system for a friend of mine who runs a traffic school.
its only going to be 5 or 6 pages but he wants all the content to be editable by him. so all the text and images on the different pages have to be stored in a DB.

and how should i structure the different tables?

Reply With Quote
  #6 (permalink)  
Old 04-06-06, 10:01
andrewst andrewst is offline
Moderator.
 
Join Date: Sep 2002
Location: UK
Posts: 5,171
Sorry, but that question is far too vague. If you no nothing at all about database design then perhaps you shouldn't offer to do this?
__________________
Tony Andrews
http://tinyurl.com/tonyandrews
Reply With Quote
  #7 (permalink)  
Old 04-06-06, 11:37
demiurgen demiurgen is offline
Registered User
 
Join Date: Apr 2006
Location: Norway
Posts: 26
ok!
how about this!

STARTPAGE (h1, h2, p1, p2, p3, li1, li2, li3, li4, li5)
PRICES (h1, h2, p1, p2, p3, p4,)
ABOUT (h1, p1, p2)
CONTACT (h1, p1, li1, li2, li3)

this is the way my DB is today. no PK and FK.
then i use a html form and php codes to write INSERT INTO and UPDATE SQL queries... it works just fine... BUT...

something tells me that this is not the way to go about making a CMS
Reply With Quote
  #8 (permalink)  
Old 04-06-06, 12:18
rajiravi rajiravi is offline
Registered User
 
Join Date: Apr 2004
Location: Toronto, Canada
Posts: 249
What are these columns called p1, p2, h1, h2, etc.?

What are these columns called h1, h2, p1, p2, etc.?

It does not look to me that you are building a data model of any sort.

If, as I suspect, h1, h2, etc. are the HTML tags, then they have no place as column names in a data model. Ask yourself, are these tags features of the problem domain, or are they merely an artifact of the technology (html) that you are using to solve the problem.

Please educate yourself on some fundamentals of relational databases so that you can ask more meaningful questions and we can provide meaningful answers to these questions.

Ravi
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On