checking a querystring

S

Shukie

Hello all,

I have a url containing query strings, e.g.
http://domain/page.asp?one=VARIABLE

I would like to be able to check what the variable is, for arguments sake,
the letter 'a' or the letter 'z'.

I have sent the query string to this,
stringone = Resquest.Querystring("one")

Then later on, I wanted to write different things depending on what the
query string returned.

IF ---the stringone IS the letter 'a' THEN
DO THIS
ELSEIF -- the stringone IS the letter 'z' THEN
DO THIS
END IF

but i dont know how to check whether the string is = to the letter 'z' or
the letter 'a'.

Thanks to all,
Shukie
 
E

Evertjan.

Shukie wrote on 01 feb 2004 in microsoft.public.inetserver.asp.general:
stringone = Resquest.Querystring("one")

Then later on, I wanted to write different things depending on what the
query string returned.

IF ---the stringone IS the letter 'a' THEN
DO THIS
ELSEIF -- the stringone IS the letter 'z' THEN
DO THIS
END IF

stringone = Resquest.Querystring("one")

if stringone = "a" then
response.write "It is: 'a'"
elsif LCase(stringone) = "z" then
response.write "It is: 'z' or 'Z'"
elseif stringone = "" then
response.write "It is: an empty string"
else
response.write "It is: some other string"
end if
 

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

No members online now.

Forum statistics

Threads
474,145
Messages
2,570,824
Members
47,369
Latest member
FTMZ

Latest Threads

Top