.htaccess or Rewrite doesnt work.

Discussion in 'Apache Migration/Compatibility' started by DJ XtAzY, Oct 23, 2007.

  1. DJ XtAzY

    DJ XtAzY Member

    Hi! Im currently on the 15day trial of ls enterprise. Hopefully i can get this solved before it's over. I have a WHM/cPanel setup and I followed the steps how to run ls with it. Im able to connect to the site fine. Currently the server has one site and runs vb with vbseo. Since vbseo rewrite links, it seems it doesn't work when I have LS running. Apache works fine though. I checked the General Tab in the Configuration area and all the boxes except None are checked. I also browse in the Virtual Host area and enable Rewrite, but still doesnt work. Some help on this will be awesome. Thanks!
  2. mistwang

    mistwang LiteSpeed Staff

    Can you please post the VBSEO rewrite rules in the .htaccess file. I think it should work well, you can also turn on the rewrite log by adding
    "RewriteLoglevel 9" to the vhost section of that virtual host. Please post the rewrite logging messages.
  3. DJ XtAzY

    DJ XtAzY Member

    Heres my .htaccess

    Code:
    # Comment the following line (add '#' at the beginning)
    # to disable mod_rewrite functions.
    # Please note: you still need to disable the hack in
    # the vBSEO control panel to stop url rewrites.
    RewriteEngine On
    
    # Some servers require the Rewritebase directive to be
    # enabled (remove '#' at the beginning to activate)
    # Please note: when enabled, you must include the path
    # to your root vB folder (i.e. RewriteBase /forums)
    #RewriteBase /
    
    RewriteRule ^((urllist|sitemap).*\.(xml|txt)(\.gz)?)$ vbseo_sitemap/vbseo_getsitemap.php?sitemap=$1 [L]
    
    RewriteCond %{QUERY_STRING} !vbseourl=
    RewriteCond %{CURRENT_URI} !(admincp/|modcp/|chat|cron)
    RewriteRule ^(.*\.php)$ vbseo.php?vbseourl=$1 [L,QSA]
    
    RewriteCond %{REQUEST_FILENAME} !\.(jpg|gif)$
    RewriteRule ^(archive/.*)$ vbseo.php?vbseourl=$1 [L,QSA]
    
    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteCond %{REQUEST_FILENAME} !-d
    RewriteCond %{REQUEST_FILENAME} !^(admincp|modcp|clientscript|cpstyles|images)/
    RewriteRule ^(.+)$ vbseo.php?vbseourl=$1 [L,QSA]
    
    RewriteCond %{HTTP_HOST} ^mysite\.net [NC]
    RewriteRule ^(.*)$ http://www.mysite.net/$1 [R=301,L]
    
    RewriteCond %{HTTP_HOST} ^www
    RewriteRule ^forums(.*)$ http://www.mysite.net/$1 [R=301,L]
    
    I have rewrite logs from Apache only for some reason. I dont see LS making any rewrite logs however. Do you want the rewrite logs from apache?
  4. mistwang

    mistwang LiteSpeed Staff

    Have you restart LSWS after the change? the rewrite log is in the main log lsws/logs/error.log at "INFO" level, so the server log level should be set to "INFO" or "DEBUG".
  5. DJ XtAzY

    DJ XtAzY Member

    Yes I have restarted LS and had the log level at INFO and DEBUG. It didnt record and Rewrite stuff.
  6. mistwang

    mistwang LiteSpeed Staff

    If you don't mind please PM me login information, I can take a look.
  7. mistwang

    mistwang LiteSpeed Staff

    This issue is addressed in upcoming 3.3 release.

Share This Page