Workshop


The workshop is designed to help you anticipate possible questions, review what you've learned, and begin learning how to put your knowledge into practice.

Quiz

1.

How is the topic ID value passed to the showtopic.php script?

2.

What else, besides telling the user the topic was successfully added, could we do at the end of the do_addtopic.php script?

Answers

1.

Through the $_GET superglobal, named as the the value of $_GET[topic_id].

2.

Just like with the replytopost.php script, we could eliminate the message display and simply redirect the user to the topic they just created, showing their new topic and post in all its glory.

Activity

You'll notice that none of these pages are really tied together with any sort of navigation. Take these basic framework scripts and apply some navigational flow to them. Make sure that the users can always add a topic or return to the topic list from any given page, for example.

If you're feeling really ambitious, use the information provided in the Q&A section to integrate and display multiple forums into your tidy little discussion board.



Sams Teach Yourself PHP MySQL and Apache All in One
Sams Teach Yourself PHP, MySQL and Apache All in One (4th Edition)
ISBN: 067232976X
EAN: 2147483647
Year: 2003
Pages: 333
Authors: Julie Meloni

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net