It's fair to says IIS7 has some differences when compared to IIS6 (Well, Duh!)
The one I found most difficult to get my head around was the Wildcard Handler Mappings. Traditionally, we wrote the handler in .net, or used the global.asax file to map the requested re-written URL to a pgae in the application. IIS6 had the option to specify whether or not the file exists.
For example, you request http://www.creative-jar.com/News. There is not physical file called News in the root, and even if there was, there's no extension on the file in the URL so IIS wouldn't know which dll to map it to, generating a 404 beacuse the file isn't found. So, you set the WildCard handler to NOT verify that the file exists, before passing it to the handler to do it's magic
It's this Verify File Exists option that's missing in IIS7, causing the 404 to fire before your handler even get's a bite of the apple.
I found a good post on the subject here. It explains the extra steps you need to get IIS7 not verifying files in your web application, instead just passing the whole request to your app and let it carry on as normal. The post links through to an open-source UrlRewriting HttpHander called UrlRewriter.NET which has such a simple setup, it's untrue. It currently uses a section of the web-config to work out it's mappings but, being that it's open-source, you can change it to collect from wherever you like
enjoy :¬)
Be the first to rate this post
- Currently 0/5 Stars.
- 1
- 2
- 3
- 4
- 5