Re: How to load another php page?
| From: | Alex Hogan | Date: | Sat, 02 Oct 2004 17:13:19 +0000 |
| Subject: | Re: How to load another php page? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-198499@lists.php.net to get a copy of this message | ||
[snip]
How can i load another php file ("another.php") directly without an action
(example: clicking on a button)?
[/snip]
If you're looking to check a condition and then add another php file
to your existing page then;
if(isset($var1)) {
include ('another.php');
or
include_once('another.php');
}
is what you're looking for.
If you're looking to redirect to another file based on a condition then;
if(isset($var)){
header('Location: another.php');
}
will work.
alex hogan