Ok I see.
You could use the
header function to re-direct the client to another page based on the value that was passed to your script.
A simple
if statement would be all that you needed. (Although there are a lot of alternatives to that.)
Something as simple as this might work:
-
<?php
-
if($_POST['pageSelection'] == "home") {
-
header("Location: index.php");
-
}
-
else if($_POST['pageSelection'] == "login") {
-
header("Location: memberLogin.php");
-
}
-
else {
-
header("Location: pageSelectionForm.html");
-
}
-
?>
-
This would simply check the value of a "pageSelection" variable, sent via a <form>. It would redirect to specific pages if it was past "home" or "login", or simple go back to the form if anything else is sent. (The page with the form being "pageSelectionForm.html")
Some people might recommend the
switch statement rather than the if statements, but I have personally never seen the point of it.