[Resolved] Content negociation and Multiviews

Status
Not open for further replies.
#1
Hi :)

I'm testing the last version of Litespeed .
On my current apache2 I use mod_negociation with multiviews .

As it's for a shared hosting, many clients can, potentially, use this functionality that is not supported by LiteSpeed.

- First question, is this something that will be added to LiteSpeed or not ?
- Second question , how can I manage that if I wanna switch form Apache2 to Litespeed ?

I have seen the code using Write rules :

Code:
RewriteCond %{REQUEST_URI} !.+php*
RewriteCond %{DOCUMENT_ROOT}/$1\.php -f
RewriteRule ^/?([^/]+)/?(.*)$ $1.php/$2 [L]
But In my case this doesn't work if I have customers using :

http://www.example.com/contact/fr

With : contact as folder
fr as a file (fr.php)

I'm not good at RewriteRules, so maybe there is a possibility to manage that ?
Same for a customers who use : http://www.example.com/contact/1/2/3/4/5/6/index

I'm looking for something generic , that can work in the most cases .

Thanks you for you help .
 
Last edited by a moderator:

NiteWave

Administrator
#2
try following rules in .htaccess:
Code:
RewriteEngine on
RewriteCond %{REQUEST_URI} !\.php$
RewriteCond %{REQUEST_FILENAME}\.php -f
RewriteRule ^(.*)$ %{REQUEST_URI}.php [L]
did tests on a local box, it works
 
Last edited by a moderator:
Status
Not open for further replies.
Top