Mod Rewrite

Hi

I have a php application that makes use of mod_rewrite for its fancy urls.

What is the easiest way to setup IIS to handle this out of the box without much if any changing of the PHP code?

As I would really like this code to be interchangable between windows and linux, so preferably, no changes to PHP.

Is this at all possible?

PS. I need to do this in both IIS 6 and 7 if possible.

There is also ISAPI Rewrite.
Version 3 has basically the same syntax as apache’s mod_rewrite, with a few minor differences.

For IIS 7 there is URL Rewrite directly from Microsoft:

You can’t use URL Rewrite for IIS6. URL Rewrite module was only possible because we rewrote IIS from scratch for IIS 7.

For IIS 6 there are a few ISAPI options available. Here’s one you can try out that’s free and open source too, http://iirf.codeplex.com/

For IIS7 you can use URL Rewrite and you can also import existing mod_rewrite rules in .htacess from Apache. Here’s an article describing that here, http://learn.iis.net/page.aspx/470/importing-apache-modrewrite-rules/

-Mark