Originally posted by Kudose
if($variable == 1){
header("Location: index.php");
} else {
header("Location: crayola.php");
}
[/B]
This is kinda what Bull's asking for.
Bull, that works for the url part I would think and if not you could use the following redirect method:
<META HTTP-EQUIV=Refresh CONTENT="0; URL=www.website.com">
For the including of the form file I'm assuming you don't want to go to a different page, you want to include a file with just a certain form in it, and just the form. In that case you would use the include function.
if that's so the basic outcome would look something like...
if($variable == 1){
//Include some form on this condition
include("formfile.php");
}
elseif($variable == 2) {
//Include some other form on this condition
include("formfile2.php");
else {
//Redirect on this condition
header("Location: crayola.php");
//If that doesn't work try this HTML method
echo "<META HTTP-EQUIV=Refresh CONTENT=\"0; URL=crayola.php\">";
}