you can find a similar question here PHP Post Request inside a POST Request but this is not working in my context.
I have a form (reservation form for a tour website) and when the form is submitted, the values are processed in a script like validation and calculation of values and sending email.
after processing the variables, i want to send it to a page for payment and this page will post payment details to paypal.
My question is after the reservation form is submitted, after processing values retrieved from reservation from, how can i redirect the page in such a way that the variables will be passed as post variables. (I am not looking from response from the other form, i want to redirect to the other form).
To create a POST request, open a up a TCP connection to the host using fsockopen(), then use fwrite() on the handler returned from fsockopen() with the same values you used in the header functions in the OP. Alternatively, you can use cURL.
Where $Message would be your variables.
EDIT: i answered this long ago maybe i did forget to reference from php.net but here is the link per comment http://www.askapache.com/htaccess/sending-post-form-data-with-php-curl.html as Reference