View Full Version : php refrence pages or self post?
resnostyle
07-19-2007, 03:36 PM
ok so I am working on a blog site. Mainly just to learn php. Currently I have 6 or 7 pages handling the requests.
I could change the code and start self posting. But I am not sure if its worth the extra hassle. Can anyone explain the importance of rewriting it to self post or is my code fine as is?
djr33
07-19-2007, 04:46 PM
I have no idea what you are talking about. Please describe it in more detail or link us to your page. Either way, I think it depends on the intent of your site, but I'm unclear about that as well.
I think you're talking about having a form and its handler on the same page. Personally, I like this approach: it modularises things nicely. However, how you do it is entirely up to you. You can have a whole site in one file if that makes sense for your site. One of the areas in which PHP excels is its flexibility as to the layout of your site (although this has its disadvantages too).
djr33
07-19-2007, 05:41 PM
Agreed, if that is the question. A simple if statement can make it work very well.
The biggest benefit is that you can interpret the data and output the form on the same page, so you can display an error message if the data was not complete, etc. If it is correct, then display the 'next page' instead.
resnostyle
07-20-2007, 12:41 AM
Agreed, if that is the question. A simple if statement can make it work very well.
The biggest benefit is that you can interpret the data and output the form on the same page, so you can display an error message if the data was not complete, etc. If it is correct, then display the 'next page' instead.
Yes, that is what i was referring to. I had a hard time trying to explain it.
Powered by vBulletin® Version 4.2.2 Copyright © 2021 vBulletin Solutions, Inc. All rights reserved.