Page 1 of 1

Problems with headers...

Posted: Wed Dec 04, 2002 8:15 pm
by aybra
Sorry Jason if you answered this... but, i have a header...

Code: Select all

<?php
header("Location: https://www.paypal.com/subscriptions/bu ... =($webplan)&item_number=1&no_note=1¤cy_code=USD&a3=($plan)&p3=($advance)&t3=M&src=1&sra=1");
?>
now.. if memory serves me right I had a working copy if this redirect at one time in my life.. but now can not for the ever loving life of me get it to work... so my question is
since i'm not doing it right... how do you transfer variables inside a header redirect???


thanks much Aybra.

Posted: Thu Dec 05, 2002 1:06 pm
by Shadough
how do you transfer variables inside a header redirect???

The same way you would any other place.

eg:

Code: Select all

header("Location: http://www.example.com/page.html?item={$item}&id={$id}&name={$name}");
exit;
You don't need the paranthesis around your variables. Use "{" "}" instead.

I also noticed this: ¤ in the URL. What's that?

I hope that helps a bit.