Problem with subfolder getting 404's with wordpress


New Member

I have openlitespeed on directadmin, I have a wordpress website on root, and perfex crm on subfolder called portal.

I'm trying to enter the crm but getting 404's, used to work fine, not sure what happened.

It only works when I remove wordpress code from htaccess only. Tried everything but not sure what is going on, any help please ?

Thanks in advance.


# BEGIN rlrssslReallySimpleSSL rsssl_version[3.3.5]
<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{HTTP:CF-Visitor} '"scheme":"http"'
RewriteCond %{REQUEST_URI} !^/\.well-known/acme-challenge/
RewriteRule ^(.*)$ https://%{HTTP_HOST}/$1 [R=301,L]
# END rlrssslReallySimpleSSL

# BEGIN WordPress
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
# END WordPress

# Wordfence WAF
<IfModule LiteSpeed>
php_value auto_prepend_file '/home/admin/domains/'
<IfModule lsapi_module>
php_value auto_prepend_file '/home/admin/domains/'
<Files ".user.ini">
<IfModule mod_authz_core.c>
Require all denied
<IfModule !mod_authz_core.c>
Order deny,allow
Deny from all
# END Wordfence WAF

RewriteEngine on
RewriteBase /portal/
RewriteCond $1 !^(index\.php|resources|robots\.txt)
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php?/$1 [L,QSA]
AddDefaultCharset utf-8
Hi @xMASEx ,

Did this happen with a specific new version after an OLS upgrade? If yes, could you downgrade back and check?
Does the crm folder has its own `.htaccess` file? If not, could you create a blank one, restart OLS and then check?


New Member
I'm not sure why it happened, I had a wordpress site with coming soon page.

2 things happened, I started working on the site, and it is now online, and yes OLS updated.

I don't know how to change the version inside directadmin though.

I tried the empty htaccess. it gave me 404, but litespeed server 404, without the htaccess it was giving me 404 inside root wordpress installation.