By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
445,771 Members | 1,685 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 445,771 IT Pros & Developers. It's quick & easy.

including POST data with header("location: ")

P: 1
Hello,

I'm building a simple shopping cart to work with PayPal.
I'd like to have the user post his basket to my page, validate the input, then redirect him _with his validated form data_ to PayPal using header("Location:"). I could just have the user submit his form to PayPal, but then I don't have any control over what he submits (tweaking the form is easy). I can include the form data as a search string in the redirect URL but that creates an even easier way to change the form data.

Anyone know if it is possible to include POST form data with a header("location:") redirect? Or another way how I could create the smallest possibility the user can change the submitted data?

Many thanks,
Hagenaer.

P.S. The form is dynamic, eliminating PayPal's encrypted form option.
Jun 10 '07 #1
Share this Question
Share on Google+
2 Replies


pbmods
Expert 5K+
P: 5,821
You can use the HTTP_Request class to accomplish this. See this thread for more info.
Jun 11 '07 #2

Motoma
Expert 2.5K+
P: 3,235
You will not be able to do this with a header, however a curl call may work for you.
Jun 11 '07 #3

Post your reply

Sign in to post your reply or Sign up for a free account.