Re: passing control to a separate script
| From: | Jim Giner | Date: | Mon, 02 May 2011 12:55:29 +0000 |
| Subject: | Re: passing control to a separate script | ||
| References: | 1 2 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-312622@lists.php.net to get a copy of this message | ||
Sorry - I responded directly to the responder - BECAUSE - I lost track of
who I was answering. That's what happens when people choose to repond to
the poster directly INSTEAD of JUST replying to the list.
Tedd gave me the 'header' directive and it works just as I imagined
something would do. See below.
>>Is this do-able?
>
> Yes, this is do-able.
>
>
> If you don't want to use a $_POST to trigger the critter, then use
> location, such as:
>
> // first script
> if($to_second_script)
> {
> header('Location:
> http://www.example.com/second.php');
> exit();
> }
>
> // second script
> if($to_first_script)
> {
> header('Location:
> http://www.example.com/first.php');
> exit();
> }
>
>
> Either those will work depending upon the trigger you need.
>
> Cheers,
>
> tedd
>
> --
> -------
> http://sperling.com/