Response.Redirect problem in Classic ASP

  • Thread starter alasdair.stirling
  • Start date
A

alasdair.stirling

Dear All,

I am new to ASP/ASP.Net and am trying to workout the exact meaning of
some old ASP Classic code. Can anyone please explain the meaning of
the following line of code:

Response.Redirect("store.asp?r=1&m=3")

In particular I need to understand the parameters (i.e. r=1&m=3) that
are being passed, and if they are defaults where can I get a listing
and explanation of their meanings and uses?

Thanks.

Alasdair Stirling
 
D

Daniel Crichton

Dear All,

I am new to ASP/ASP.Net and am trying to workout the exact meaning of
some old ASP Classic code. Can anyone please explain the meaning of
the following line of code:

Response.Redirect("store.asp?r=1&m=3")

In particular I need to understand the parameters (i.e. r=1&m=3) that
are being passed, and if they are defaults where can I get a listing
and explanation of their meanings and uses?

They are query string parameters. If you look in the store.asp code you'll
likely find it reads the values of Request.QueryString("r") and
Request.QueryString("m") and does something with them. Outside of code
within the store.asp page they are meaningless.

Dan
 
M

Mike Brind

Dear All,

I am new to ASP/ASP.Net and am trying to workout the exact meaning of
some old ASP Classic code. Can anyone please explain the meaning of
the following line of code:

Response.Redirect("store.asp?r=1&m=3")

In particular I need to understand the parameters (i.e. r=1&m=3) that
are being passed, and if they are defaults where can I get a listing
and explanation of their meanings and uses?

No one can tell you what the parameters are without looking at the code
in store.asp. In that file, there should be some conditional logic
that will look for the values of Request.QueryString("r") and
Request.QueryString("m"), and take certain actions as a result of those
values.

There is no such thing as default parameters or values in Classic ASP
querystrings. "r" and "m" could just as well have been called "mouse"
and "stopstandingonmyfoot" with any string as the value (as in
store.asp?mouse=sink&stopstandingonmyfoot=2234cfd4). r and m and 1 and
3 would no doubt (I mean probably) have had some meaning to the
original programmer, which might be discerned from the code.

Response.Redirect will redirect the browser to the store.asp page, with
those parameters in the querystring
 
B

Bob Barrows [MVP]

Dear All,

I am new to ASP/ASP.Net and am trying to workout the exact meaning of
some old ASP Classic code. Can anyone please explain the meaning of
the following line of code:

Response.Redirect("store.asp?r=1&m=3")

In particular I need to understand the parameters (i.e. r=1&m=3) that
are being passed, and if they are defaults where can I get a listing
and explanation of their meanings and uses?
This is a querystring, which has exactly the same function in ASP.Net as
it had in classic ASP.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,598
Members
45,144
Latest member
KetoBaseReviews
Top