Openlitespeed doesn't recognise rewrite base rewrites

Discussion in 'Bug Reports' started by wanah, May 11, 2014.

  1. wanah

    wanah Member

    Hello,

    I've just started testing openlitespeed. I had to modify my rewrite rules from :

    RewriteBase /
    RewriteRule ^forum\.html$ /forum/index.php [QSA,L,NC]

    to :

    RewriteRule ^/forum\.html$ /forum/index.php [QSA,L,NC]

    Is this normal ?

    Thanks :)
  2. NiteWave

    NiteWave Administrator

  3. wanah

    wanah Member

    I put it in the openlitespeed admin pannel.

    I expected :

    RewriteBase /
    RewriteRule ^forum\.html$ /forum/index.php [QSA,L,NC]

    to work but it did not and it seems that openlitespeed doesn't understand RewriteBase which is a shame as losts of script except this code to work.
  4. Michael

    Michael Administrator Staff Member

    Howdy,

    The important thing to remember here is that the WebAdmin console acts like an httpd.conf file. The RewriteBase directive is only for .htaccess files. We may figure out a workaround for this in the future, but, for the time being, just remember that all rewrites should be written as though they are going into an .htaccess file.

    Cheers,

    Michael
  5. wanah

    wanah Member

    Hello Michael, I'm sorry but I think you have said two different things :

    he WebAdmin console acts like an httpd.conf file
    just remember that all rewrites should be written as though they are going into an .htaccess file.

    So should I write the rewrites like a .htaccess file or like httpd.conf file ? Because the rewrites that didn't work were taken from an existing .htacess file that works with litespeed enterprise.
  6. Michael

    Michael Administrator Staff Member

    Oops. Yes, all rewrites should be written as though they are going into an httpd.conf file...

    Sorry about that...

    m
  7. wanah

    wanah Member

    OK thanks, shame I was hopeing it was possible to copy / paste the contents of the main .htaccess file to the openlitespeed web admin…
  8. Michael

    Michael Administrator Staff Member

    I understand completely. This is something we will be considering in the future as we try to make OpenLiteSpeed easier to use.

    Cheers,

    Michael

Share This Page