Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

posting data with an HTTP redirection

Status
Not open for further replies.

naq2

Programmer
Aug 3, 2004
74
FR
This is not documented in the CPAN documentation on the CGI module.

Normally, to do some HTTP redirection, I'll use:
Code:
print $myCGI->redirect("[URL unfurl="true"]http://mynewurl.com/toto.html")[/URL] ;

This is great... but... what happens if I want to post data to this URL I'm asking for a redirection.
How do I do this?

Thanks for you help.
 
Are you against printing out a form with the data in hidden fields and then submitting it onLoad?

I don't know right off-hand a way to do it directly from the server.
 
I simply can't use such a solution, because the output is not going to a web browser. :S
 
Code:
print $myCGI->redirect("[URL unfurl="true"]http://mynewurl.com/toto.html?var1=data&var2=data2")[/URL] ;
is how I'd normally pass data to a cgi script, but html, dunno.
I suppose you could write some javascript to poplulate your form variables from the Query String

HTH
--Paul



It's important in life to always strike a happy medium, so if you see someone with a crystal ball, and a smile on their face ...
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top