PDA

View Full Version : Bizzare .htaccess Issue


mhere
04-27-2009, 09:42 AM
First of all, yes, I did read all other threads relating to this first :)

Ok, right.

My System:

WHM/Litespeed

It's al installed, working fine and very fast, no problems there. The issue is that I'm not able to have both a .htaccess pwd and the wordpress rewrite working at the same time :s

Either rule works perfectly alone, but when they're in the (same oc) .htaccess file together it just loads the naked php (with no css/js/imgs) and none of the links work. Nor does it ask for a password.

Both work perfectly alone.

Here's my .htaccess file, mabe it's incorrect, I know my way around a server but I'm hardly an expert.

AuthType Basic
AuthName "Woah, come back in around 48 hours"
AuthUserFile "/home/xxxxxxxxx/xxxxxxxxxxxxx/public_html/passwd"
require valid-user

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

# END WordPress

Thanks

Richard
04-27-2009, 10:34 AM
We seem to be having a similar issue, http://www.litespeedtech.com/support/forum/showthread.php?t=2919.

mistwang
04-27-2009, 12:25 PM
I think the issue is that a custom error page for 401 has been defined in the configuration, but the file does not exist for your vhost, so the 401 reply will be rewritten to index.php.

Try adding a 401 page under the document root, usually, it is /401.shtml for cPanel server.

mhere
04-27-2009, 01:03 PM
I think the issue is that a custom error page for 401 has been defined in the configuration, but the file does not exist for your vhost, so the 401 reply will be rewritten to index.php.

Try adding a 401 page under the document root, usually, it is /401.shtml for cPanel server.

Yep, that's fixed it, thanks a lot :)

Richard
04-27-2009, 05:02 PM
edit: nevermind... got it working