Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > .NET General

Vista - redirect based on URL entered

Reply
 
Old 11-18-2008   #1 (permalink)
JR


 
 

redirect based on URL entered

I have a website that has some issues depending on what URL a user
uses. If they type in http://www.url.com it works fine. If they go
to http://url.com it has issues. This is the issue with two URL's on
the same IIS instance. How would you do the following?

if <URL entered to get here> = "url1.com" go to http://www.url1.com
else if <URL entered to get here = "www.url1.com" go to http://www.url1.com
else if <URL entered to get here> = "url2.com" go to http://www.url2.com
else if <URL entered to get here = "www.url2.com" go to http://www.url2.com

Again thinking some kind of asp/aspx page that needs to run in IIS.
Any ideas?

Thanks.

JR

My System SpecsSystem Spec
Old 11-18-2008   #2 (permalink)
JR


 
 

Re: redirect based on URL entered

Slight correction as this would endless loop:

if <URL entered to get here> = "url1.com" go to http://www.url1.com/home2.asp
else if <URL entered to get here = "www.url1.com" go to http://www.url1.com/home2.asp
else if <URL entered to get here> = "url2.com" go to http://www.url2.com/home2.asp
else if <URL entered to get here = "www.url2.com" go to http://www.url2.com/home2.asp
My System SpecsSystem Spec
Old 11-19-2008   #3 (permalink)
Andrew Morton


 
 

Re: redirect based on URL entered

JR wrote:
Quote:

> I have a website that has some issues depending on what URL a user
> uses. If they type in http://www.url.com it works fine. If they go
> to http://url.com it has issues.
You need to state *exactly* what those issues are. We can't see your monitor
from here...
Quote:

> This is the issue with two URL's on
> the same IIS instance.
I suspect that either you haven't set up DNS for both URLs or you haven't
set the host headers for both URLs in IIS.

Andrew


My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
prompt function and the last command entered PowerShell
Excel Date Entered Microsoft Office
I entered wrong information... Vista installation & setup
Re: using xp based drive as slave on new vista based computer?? Vista installation & setup
Freezes RIGHT AFTER validation key is entered. Vista installation & setup


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46