Well, you could solve this in a pretty generic way, by iterating over
the Request.Form collection, generating a form with corresponding
hidden variables. And in the end, you include a Javascript that simply
submits the form (rather than doing a redirect).
Consider this simple function:
ForwardForm "x3.asp"
Sub ForwardForm(pstrURL)
Dim strKey
Response.Write("<form method=""post"" action=""" & pstrURL & """
name=""forwardForm"">")
For Each strKey In Request.Form
Response.Write("<input type=""hidden"" name=""" & strKey & """
value=""" & Request.Form(strKey) & """>")
Next
Response.Write("</form>")
Response.Write("<script language=""javascript"">")
Response.Write("if (document.forwardForm)
document.forwardForm.submit();")
Response.Write("</script>")
End Sub
Please note that you might need to escape certain characters (").
Regards,
Johan
"Agoston Bejo" <gu***@freemail.hu> wrote in message news:<O0**************@TK2MSFTNGP14.phx.gbl>...
The main point is not having to know what exactly is in Request.Form AND not
having to create forms for a simple redirect. (This latter could be
generated based on Request.Form but then I would need a javascript that
redirects a page etc. - too much work!)
"André Nobre" <Andr No***@discussions.microsoft.com> wrote in message
news:A9**********************************@microsof t.com... You can use hidden fields to do this, redirecting from x2 to x3 with java
script.
"Agoston Bejo" wrote:
Hi.
x1.asp:
<form method="post" action="x2.asp"> .... </form>
x2.asp:
DoSomeAdministration()
Response.Redirect "x3.asp?" & Request.Form
x3.asp: further processsing of data
This scenario works for a certain amount of data, but passing data in
Request.QueryString has its limits.
Is there any other way so that x3.asp can retrieve the data posted in
x1.asp? I could put the textual representation of Request.Form into a
session variable, but it would be much easier if I could pass on
Request.Form so that x3.asp would be able to access it the same way as it could if x1.asp posted directly to x3.asp.