URL Rewrite problems

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi all,

I am developing a ASP.NET 2.0 application that must use friendly URLs. As an
example, a content in http://www.mysite.com/music/pearljam for instance
should be rewritten to http://www.mysite.com/Artist.aspx?id=1. The problem I
am having is the fact the url doesn't have an .aspx extension and so IIS
doesn't forward the request to the ASP.NET engine and I can't make the
rewrite with ASP.NET events (Application_BeginRequest for example). IIS
simply gives the 404 error and the request doesn't even reach the ASP.NET
engne. What is the workaround for this? Is there any setting that makes IIS
forward requests without extension to ASP.NET engine. My rewrite engine is
already working for .aspx pages but not for cases that the the extension is
not present. I tried to add an .* extension to the IIS metabase and point it
to the ASP.NET 2.0 isapi but it doesn't work.
I am using Windows XP SP2 and IIS5.1 and have .NET Framework 1.1 and 2.0
installed.

Thanks in advance
Miguel
 
Take a look at ISAPIREWRITE_LITE (free version). What you may need here is an
ISAPI filter, which works at the IIS level, way before the request gets
forwarded to ASP.NET for processing. It has the same REGEX features.
Peter
 
Back
Top