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 gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Querystring question

Status
Not open for further replies.

dellyjm

Programmer
Apr 13, 2000
168
JM
Hey everyone, need your help on this. Look @ code below.

For Each strName In Request.QueryString
Response.Write strName & " - " & Request.QueryString(strName)
Response.Write &quot;<BR>&quot;
Next

TransEmpid - 00480, 00480, 00480, 00480, 00480
TranMod - Personal, Personal, Personal, Personal, Personal
TransFld - hrnation, hrmarstat, ipfirst, hremgrel, hremgcon
TransId - 6, 5, 4, 3, 2

I now want to loop through the data and get the information for the first set (before the commas) and the sets following. Anyone have any code to help me.

Delton.
deltonphillips@hotmail.com
 
you can use the split function to parse the string --

TransEmpid = &quot;00480, 00480, 00480, 00480, 00480&quot;

array = split(TransEmpid, &quot;, &quot;)

you now have a five element array with the different part of the string in each --

good luck! :)
Paul Prewett
 
Thanks alot and God is going to bless you.

Delton Phillips.
deltonphillips@hotmail.com
 
How do i pass something like &quot;Fred Couples&quot; in the querystring?

Delton.
 
use Server.URLEncode

strTmp = Server.URLEncode(&quot;Fred Couples&quot;)
<a href=&quot;aaa.asp?name=<%=strTmp%>&quot;>test</a>

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top