Perl-Sensitive Sunglasses | |
PerlMonks |
Re^3: CGI Cookiesby CountZero (Bishop) |
on Feb 18, 2008 at 15:43 UTC ( [id://668573]=note: print w/replies, xml ) | Need Help?? |
Putting all pages in one script might actually be a good idea. As long as you make a hidden parameter in each of your forms with the number of the stage, your script will be able to direct the input to the right routine and you benefit from having all "common" routines in one place, rather than being repeated in all your scripts. Especially the connection to the database will benefit from being only defined once (if you ever have to change anything concerning the database, you make changes in ony one place). Also all standard matters, such as headers & footers, CSS, Javascript, Cookies, ... will all be found in one spot. CountZero A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James
In Section
Seekers of Perl Wisdom
|
|