asp redirect problem

Reply

Join Date: Jul 2008
Posts: 1
Reputation: ruben.rens is an unknown quantity at this point 
Solved Threads: 0
ruben.rens ruben.rens is offline Offline
Newbie Poster

asp redirect problem

 
0
  #1
Jul 31st, 2008
Hi, new here, but have read the previous threads on redirect problems:
We are running a default.asp file on a IIS 2000 server that handles redirects for us. Until now all has been working 100%, but I am having trouble adding a new redirect to this file. I need to point out that I am very green when it comes to asp, but hopefully fast learner.

The ISP confirmed that a sub domain we registed is active and has propagated.
When I updated the asp file, I get a http 404 error when I request the new addition - http://order.mysite.co.za - which I want to point to https://secure.mysite.co.za/*.*

The bizarre thing is that in trying to eliminate possible reasons, I went and changed an existing line of code by simply pointing it to the desired URL - and when I tried that it worked - but obvisouly for the wrong sub domain?

Any ideas what I might have done wrong?

The code looks like this (removed the real URL's)

  1. <%
  2. Session.Timeout = 720
  3. select case Request.ServerVariables("HTTP_HOST")
  4. case "www.mysite.co.za"
  5. session("SiteName") = "My site"
  6. response.redirect "pages/index/index.php"
  7.  
  8. case "promotion.mysite.co.za"
  9. session("SiteName") = "My site"
  10. response.redirect "pages/personal/*.php"
  11.  
  12. case "apply.mysite.co.za"
  13. session("SiteName") = "My site"
  14. response.redirect "https://secure.mysite.co.za/*.*"
  15.  
  16. case "wine.mysite.co.za"
  17. session("SiteName") = "My site"
  18. response.redirect "pages/wine_society/*.*"
  19.  
  20. case "dine.mysite.co.za"
  21. session("SiteName") = "My site"
  22. response.redirect "pages/personal/*.*"
  23.  
  24. case "golf.mysite.co.za"
  25. session("SiteName") = "My site"
  26. response.redirect "pages/personal/*.*"
  27.  
  28. case "travel.mysite.co.za"
  29. session("SiteName") = "My site"
  30. response.redirect "pages/travel/*.*"
  31.  
  32. case "prive.mysite.co.za"
  33. session("SiteName") = "My site"
  34. response.redirect "/prive/*.*"
  35.  
  36. case "advantage.mysite.co.za"
  37. session("SiteName") = "My site"
  38. response.redirect "https://secure.mysite.co.za/*.*"
  39.  
  40. case "order.mysite.co.za"
  41. session("SiteName") = "My site"
  42. response.redirect "https://secure.mysite.co.za/*.*"
  43.  
  44. case else
  45. session("SiteName") = "My site"
  46. response.redirect "pages/index/*.*"
  47.  
  48. end select
  49. %>
Last edited by peter_budo; Aug 1st, 2008 at 1:33 pm. Reason: Keep It Organized - please use [code] tags
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:




Views: 2600 | Replies: 0
Thread Tools Search this Thread



Tag cloud for ASP
About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC