Mobile app version of vmapp.org
Login or Join
BetL925

: It seems you're mixing Wordpress itself, which tries to do a redirect, and the RewriteRule, where you don't have to do a redirect: it's rewritten internally before arriving to Php, thus before

@BetL925

It seems you're mixing Wordpress itself, which tries to do a redirect, and the RewriteRule, where you don't have to do a redirect: it's rewritten internally before arriving to Php, thus before arriving to Wordpress. If you just stop rewriting and add the QSA flag to always keep the query string, this should do the trick.

Try to do this:

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /index.php/ [QSA,L]


If it doesn't work, try to do this:

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ /index.php/ [QSA,L]


If it doesn't work, try to do this:

RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !(index.php)
RewriteRule ^(.*)$ /index.php/ [QSA,L]


And if that's not enough:

Two hints:

If you're not in a hosted environment (= if it's your own server and you can modify the virtual hosts, not only the .htaccess files), try to use the RewriteLog directive: it helps you to track down such problems:

# Trace:
# (!) file gets big quickly, remove in prod environments:
RewriteLog "/web/logs/mywebsite.rewrite.log"
RewriteLogLevel 9
RewriteEngine On




My favorite tool to check for regexp:
www.quanetic.com/Regex (don't forget to choose ereg(POSIX) instead of preg(PCRE)!)

10% popularity Vote Up Vote Down


Login to follow query

More posts by @BetL925

0 Comments

Sorted by latest first Latest Oldest Best

Back to top | Use Dark Theme