Click to See Complete Forum and Search --> : Article systems


benson
01-14-2004, 06:31 AM
Hi,
I want too create an article system.
So i've checked the net for aticle systems. Not very much found wich suits my needs. So i decided for my own intellect :p to create such an system myself. So i have been thinking what i should doo, how to set up the db and how too script.
Now i have come to the conclusion that i have no clue how too set it up properly. I have an idea though. Thinking the kind people of phpbuilder would help i've come here too ask if my suggested setup would be correct.

DB:
:> ID
:> Titel name
:> Date
:> article field.
:> Nickname

scripting:
Have an index.php page wich has too show al the titel names.
And behind it the date's (that's simple).
An extra page search.php wich can search the text OR the titel name (have no clue).
An page only members where you can make an article (Possible for me too make).


Have i overlooked something or do you have tips ?
Please post so i can learn :P

Thanks in advance for all reply's and considerations,
Benson

Natty_Dreadlock
01-14-2004, 10:21 AM
it seems u got everything u need in order to create a simple article system. if u wanna include a search function u might use a msl query like this:
SELECT id FROM db WHERE article_text LIKE '%$searchWord%'
Provided $searchWord is the query the user submitted. To prevent sql injection attacks, u should apply the mysql_escape_string function(http://www.php.net/mysql_escape_string). If u got more questions, feel free to ask.
hth

benson
01-14-2004, 11:01 AM
Ok,
But how should i set the db rows ?
Blob or something ?

Natty_Dreadlock
01-14-2004, 02:07 PM
i'd suggest:
:> ID - int
:> Titel name - varchar
:> Date - varchar or date
:> article field - text
:> Nickname - varchar
hht