Well to create a subpage in a script file, the easiest way is to define variables such as $page, $act or $more as super global array $_GET['page'], $_GET['act'], or $_GET['more']. This way you can continue to create a PHP form that direct the user to a certain page under certain conditions. The page and url info is stored in the super global $_GET, and thus can be readily extracted to use.
A very good example is account.php, in which the variable $act can have several values, each leading to a different subpage that users can edit their account info. A problem arises if you are creating a game script incase you do not want users to be able to cheat with the 'refresh' and 'back' button. The manipulation of PHP session variables will resolve this issue, but for now its your best interest not to worry about it till later.
__________________
Mysidia Adoptables, a free and ever-improving script for aspiring adoptables/pets site.
|