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

QueryString->Object?

Status
Not open for further replies.

mthrawn

Programmer
Aug 17, 2000
42
GB
I have two pages. one generates a tables of results based on parameters sent through the querystring by the other.

I want to perform a match method on these parameters, which requires the parameters to be strings (which is what I thought they would be). However, the match method failed and when I returned the typeof(parameter) to the screen it gave me 'object'. I've tried using parameter.toString(), I've tried creating a temp variable as a String() and assigning the parameter value to it but it seems whatever I do I just can't get those parameters to behave like strings... I'm begging you, HELP ME!!!
Matt
Tubedale Communications Ltd (Bristow-Solutions (Software Developer
 
Dear Matt,

This should work, if it doesn't please show any error messages that you receive.

var stemp = new String( Request("myvar"));
// now call a Javascript.String method
stemp = stemp.toUpperCase();

Hope this helps
-pete
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top