Passing Parameters to new ASP form (Full Version)

All Forums >> [Web Development] >> ASP and Database



Message


mseal1 -> Passing Parameters to new ASP form (5/7/2002 10:21:05)

Hi,
I’m trying to pass several parameters through several ASP forms that.
Most of the data is extracted from a Db using a DRW. How can I assign a parameter the value from the DRW and pass it to the second ASP form. Once there, how to I grab it?
A second question…. Once I ‘grab’ the parameter, how do I use it in a VBScript or Java script?

Thanks
Motty




rdouglass -> RE: Passing Parameters to new ASP form (5/7/2002 12:31:30)

If they're form-based, just grab the value from the submitting form by using:

<%=Request.Form("fieldName")%>

where fieldName is the name of the input item on the submitting form.

That will allow you to use it in VBScript. Not sure about JavaScript....

 




mseal1 -> RE: Passing Parameters to new ASP form (5/7/2002 13:51:51)

Thanks…
But I’m using a DRW result region defined as a table, and using a hyperlink so users can select a specific ‘record’. The Hyperlink in passing the record parameters via the link, but I have general session information that I need to pass from form to form. The original call is not a POST but a hyperlink (does that change the method?)

Thanks
Motty






rdouglass -> RE: Passing Parameters to new ASP form (5/7/2002 14:39:29)

You'd grab hyperlink parameters similarly:

<%=Request.Querystring("parameterName")%>

 




mseal1 -> RE: Passing Parameters to new ASP form (5/7/2002 14:42:31)

Is there a way to pass it hidden, I have many values to run and would like not to place them all on the hyperlink line?

Thanks
Motty






rdouglass -> RE: Passing Parameters to new ASP form (5/9/2002 15:09:19)

Instead of passing long hyperlink parameters, why couldn't you just pass the record ID and grab the data on the next page? If you're dealing with lots of different items (you talked about session variables and stuff), have you considered using cookies?

Sorry about not having clear answers, but the questions are a little cloudy to me. Do you have any more specifics you can share? How many parameters? What kind are they? Are they static (like username, login time, etc) or are they dynamic (current item selected, etc.).

Generally, if you have a lot of items you're trying to pass in a hyperlink, and they originally came from a DB, its usually easier to just pass the ID and grab 'em again on the next page. If they're 'session' items (static throughout the visit to the site), its usually easier to use session variables or cookies.

At least IMO....

 




adambrooks -> RE: Passing Parameters to new ASP form (5/9/2002 15:43:03)

You can post and call the values from a cookie or session data. There are some pretty basic tutorials about it on w3schools.com

Adam Brooks
http://www.ATonline.com





Page: [1]

Valid CSS!




Forum Software © ASPPlayground.NET Advanced Edition 2.4.5 ANSI
0.0625