Index: includes/bootstrap.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/bootstrap.inc,v
retrieving revision 1.257
diff -u -r1.257 bootstrap.inc
--- includes/bootstrap.inc	3 Dec 2008 14:51:53 -0000	1.257
+++ includes/bootstrap.inc	18 Dec 2008 23:22:13 -0000
@@ -844,6 +844,14 @@
  */
 function request_uri() {
 
+  // ISAPI_Rewrite cannot set REQUEST_URI in IIS, but provides the same value
+  // via HTTP_X_REWRITE_URL and allows us to build Apache compatibility in the
+  // following way.
+  // For more information see http://www.helicontech.com/isapi_rewrite/doc/concept.htm.
+  if (isset($_SERVER['HTTP_X_REWRITE_URL'])) {
+    $_SERVER['REQUEST_URI'] = $_SERVER['HTTP_X_REWRITE_URL'];
+  }
+
   if (isset($_SERVER['REQUEST_URI'])) {
     $uri = $_SERVER['REQUEST_URI'];
   }
