Wordpress rewrite rules

jkeegan

Active Member
#1
I am using the latest (3.37) Litespeed and trying to use it as an Apache replacement for serving Wordpress sites on Plesk. LSWS is configured to use apache's configuration, we want to be able to make changes in Plesk and have Litespeed pick up the changes.

Using a simple Plesk vhost.conf:

<Directory />
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</Directory>

I shut down apache and start up lsws. The home page of the Wordpress site gets served, but any permalinks, which would have required the rules above, do not. Just see a 404.

Apache picks up the conf above just fine.

Any idea what the issue is?
 

mistwang

LiteSpeed Staff
#2
LSWS won't check the rewrite rules in <Directory /> .
You should move it to the directory of the real virtual host document root or .htaccess

Even though it works with Apache, to me, it is not appropriate to use "RewriteBase /" there as that is not the document root, causes inconsistency.
 
Top