Code Bank
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
 
 
User Name:
Password:
Remember me
Go Back   ASP Free ForumsProgrammingCode Bank

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread ASP Free Forums Sponsor:
  #1  
Old July 23rd, 2004, 07:20 AM
commekid commekid is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Jul 2004
Location: UK
Posts: 19 commekid User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via ICQ to commekid Send a message via MSN to commekid Send a message via Yahoo to commekid
Query Strings

hay all,
ive been experimenting with query strings lately and would like to know if there is like an if function i could program, like if its a certain string variable like *.asp?id=1 so i could make it redirect if it its a certain id number,
any help on the this would be much appreciated or another way to do this system would be greatly accepted,
thanx all in advance,
commekid

Reply With Quote
  #2  
Old July 23rd, 2004, 10:01 AM
selwonk's Avatar
selwonk selwonk is offline
Contributing User
ASP Free Frequenter (2500 - 2999 posts)
 
Join Date: Jun 2004
Posts: 2,942 selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level) 
Time spent in forums: 6 Days 9 h 49 m 28 sec
Reputation Power: 62
Hi

Code:
Select Case CInt(Request.QueryString("id"))
Case 1
Response.Redirect("1.asp")
Case 2
Response.Redirect("2.asp")
Case Else
Response.Redirect("noid.asp")
End Select


Cheers

MK

Reply With Quote
  #3  
Old July 23rd, 2004, 10:54 AM
commekid commekid is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Jul 2004
Location: UK
Posts: 19 commekid User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via ICQ to commekid Send a message via MSN to commekid Send a message via Yahoo to commekid
Thumbs up

thanx selwonk,

once again lol
this works perfectly,
do you know howto like mask it so when you click it it still redirects but in the address bar it stays as *.asp?id=1
?
thanx anyway
commekid

Reply With Quote
  #4  
Old July 23rd, 2004, 11:03 AM
selwonk's Avatar
selwonk selwonk is offline
Contributing User
ASP Free Frequenter (2500 - 2999 posts)
 
Join Date: Jun 2004
Posts: 2,942 selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level)selwonk User rank is Second Lieutenant (5000 - 10000 Reputation Level) 
Time spent in forums: 6 Days 9 h 49 m 28 sec
Reputation Power: 62
You would have to do this with a frame but it's probably more effort than it's worth

MK

Reply With Quote
  #5  
Old July 23rd, 2004, 11:20 AM
commekid commekid is offline
Registered User
ASP Free Newbie (0 - 499 posts)
 
Join Date: Jul 2004
Location: UK
Posts: 19 commekid User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via ICQ to commekid Send a message via MSN to commekid Send a message via Yahoo to commekid
ok thanx anyway

Reply With Quote
Reply

Viewing: ASP Free ForumsProgrammingCode Bank > Query Strings


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway