Sign In| Join
Get Help:Ask a Question in our Forums|Report a Bug|More Help Resources
Last post May 09, 2012 12:45 AM by ericyzhou
Member
2 Points
23 Posts
May 08, 2012 07:03 AM|LINK
In case I am having an web page which is: http://localhost:2345/cms/content.aspx
I would like to make the page browsable by url: http://localhost:2345/content.aspx
How may I do this in asp.net? Or do I have to change some settings in IIS?
url webform
May 08, 2012 08:29 AM|LINK
I know I can do this with httphandler, but this is what I am trying to avoid. I wonder if I can accomplish this by just the web.config file editing or some sort.
All-Star
42975 Points
7025 Posts
MVP
May 08, 2012 01:47 PM|LINK
Hello,
No need of HTTP handlers. You can use URL rewrite to accomplish this. Check the below article in ScottGu's blog too
http://weblogs.asp.net/scottgu/archive/2007/02/26/tip-trick-url-rewriting-with-asp-net.aspx
If you are confused what to use, URL routing or URL rewrite, following links will help you to choose what's needed for you
http://learn.iis.net/page.aspx/496/iis-url-rewriting-and-aspnet-routing/
http://haacked.com/archive/2010/01/17/editable-routes.aspx
Please 'Mark as Answer' if this post helps you.
May 09, 2012 12:45 AM|LINK
This really helps, thank you Ruchira.
ericyzhou
Member
2 Points
23 Posts
How may I used an alias url link for a web page in asp.net?
May 08, 2012 07:03 AM|LINK
In case I am having an web page which is: http://localhost:2345/cms/content.aspx
I would like to make the page browsable by url: http://localhost:2345/content.aspx
How may I do this in asp.net? Or do I have to change some settings in IIS?
url webform
ericyzhou
Member
2 Points
23 Posts
Re: How may I used an alias url link for a web page in asp.net?
May 08, 2012 08:29 AM|LINK
I know I can do this with httphandler, but this is what I am trying to avoid. I wonder if I can accomplish this by just the web.config file editing or some sort.
Ruchira
All-Star
42975 Points
7025 Posts
MVP
Re: How may I used an alias url link for a web page in asp.net?
May 08, 2012 01:47 PM|LINK
Hello,
No need of HTTP handlers. You can use URL rewrite to accomplish this. Check the below article in ScottGu's blog too
http://weblogs.asp.net/scottgu/archive/2007/02/26/tip-trick-url-rewriting-with-asp-net.aspx
If you are confused what to use, URL routing or URL rewrite, following links will help you to choose what's needed for you
http://learn.iis.net/page.aspx/496/iis-url-rewriting-and-aspnet-routing/
http://haacked.com/archive/2010/01/17/editable-routes.aspx
My Tech blog | My YouTube ChannelPlease 'Mark as Answer' if this post helps you.ericyzhou
Member
2 Points
23 Posts
Re: How may I used an alias url link for a web page in asp.net?
May 09, 2012 12:45 AM|LINK
This really helps, thank you Ruchira.