URL Formatting On IIS
-
Just thought I would stop by and let you know that in the WordPress.php in modules grabs the REQUEST_URI global. Most of the time this works but on IIS, the GLOBAL REQUEST_URI is provided without encoding (%20). Most all browser encode before sending the request making the check invalid if there is a redirect entry that contains a space.
In the Class WordPress_Module inside the method “init”; ideally you would convert this to an encoded URL to make the REQUEST_URI universal and always the same format (all all OS).
Changing the line from:
$url = $_SERVER['REQUEST_URI'];
TO
$url = str_replace(' ', '%20', $_SERVER['REQUEST_URI']);
would allow redirects on Windows servers that contain a space to be redirected as well.
- The topic ‘URL Formatting On IIS’ is closed to new replies.