JasonWoof Got questions, comments, patches, etc.? Contact Jason Woofenden
work around REDIRECT_URL in apache 2.4.17
[wfpl.git] / main.php
index dc1199b..6e05009 100644 (file)
--- a/main.php
+++ b/main.php
@@ -49,6 +49,7 @@ function wfpl_main($dest = false) {
 
        } else { # no dest arg
                $basename = $_SERVER['REDIRECT_URL'];
+               $basename = preg_replace('|[?].*|', '', $basename); # apache 2.4.17
                $basename = preg_replace('|.*/|', '', $basename);
                $basename = preg_replace('|\.html?$|', '', $basename);
                if($basename == '') {