Posted on: 01/18/04 03:32pm
By: MrPilot
Perhaps this would be the proper board to add this question to:
I would like to add a line to my displayed articles similar to the slashdot-style "xxx-xxx-dept" display. I have no idea where to begin, and I would like to do this myself. Where do I start? Would I just look at the "Adds the story to the database" section in story.php and add "$dept" code like the other parts of the article?
Or is this PHP newbie getting in way over his head? :-)
Thanks,
MrP
Re:Adding "Slashdot" style "xxx-xxx-dept" to posted articles
Posted on: 01/18/04 11:32pm
By: Turias
Do you want them all to be the same? Or do you want the story submitter to be able to choose a dept? Or do you want it to be random?
Re:Adding "Slashdot" style "xxx-xxx-dept" to posted articles
Posted on: 01/19/04 12:05am
By: Anonymous (MrPilot)
I would like the story submitter to be able to make up whatever dept they want (with a reasonable character limit - maybe 50 or so) when they submit the story. The line would be in the format of "from the [whatever dept user makes up] dept". I imagine I could figure out how to edit the template file to add the surrounding text, I just need to know how to let the user compose a department and how to store and retrieve it from the gl_stories database table.
Thanks!
MrPilot
Re:Adding "Slashdot" style "xxx-xxx-dept" to posted articles
Posted on: 01/19/04 09:40am
By: Turias
That's going to require altering the table and doing a lot of hacking. Just examine the code where stories are added and retrieved from the database. You'll have to make quite a few changes, though.
Re:Adding "Slashdot" style "xxx-xxx-dept" to posted articles
Posted on: 01/19/04 09:57am
By: Dirk
[QUOTE BY= Turias] That's going to require altering the table[/QUOTE]
Also, please note that we do not recommend making changes to Geeklog's tables. Instead, you should create your own tables (which, I'm afraid, is even more work ...).
bye, Dirk