This is a discussion on RE: [PHP] Re: function help simple redirect within the PHP General forums, part of the PHP Programming Forums category; On Monday, October 27, 2003 11:26 AM, Frank Tudor wrote: > This one worked (kinda)!!!! > I have no ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
On Monday, October 27, 2003 11:26 AM, Frank Tudor wrote:
> This one worked (kinda)!!!! > I have no more errors but it doesn't do the redirect (hmmm)?? > <?PHP > $payment = "1"; > > function payment(){ > global $payment; > if ($payment == "0"){ > header ('Location: http://ftudor/test/test_page.html'); > > } > elseif ($payment == "1") { > header ('Location: http://ftudor/test/test_page2.html'); > > } > } > ?> You need to add payment(); to your php code. The function is defined, but it's not going to do anything until you call it. Cheers, Pablo |