htaccess configuration issue

#1
On my .htaccess, I have something like this
RewriteRule ^([a-zA-Z0-9.-]+)/([a-zA-Z0-9.-]+)/good-world/?$ /good-earth.php?product=$1&pid=$2[L]

Although the script load, however for an unknown reason, it does not work properly again. I think the PHP file_get_contents does not work

Also, I have a folder name myfolders. If I visit https://mysite.com/myfolders/users it will not work but if I visit https://mysite.com/myfolders/users.php it will work.

I have followed the instruction on https://www.litespeedtech.com/suppo...config:multiviews#how_apache_multiviews_works
but it seems that it is not complete. Different examples were not given

Please how can I achieve the result
 
Last edited by a moderator:
#3
please show contents of myfolders/.htaccess
I do not understand. In the myfolders are some php files. One of the files is users.php. If I right https://mysite.com/myfolders/users.php it will work but if i remove the .php it will not work

Also while is file_get_contents no longer work. If I switch to Apache, it works but on Litespeed, it does not work.
 
Last edited by a moderator:

NiteWave

Administrator
#4
Also while is file_get_contents no longer work. If I switch to Apache, it works but on Litespeed, it does not work.
please compare the difference of phpinfo between litespeed and apache.

please provide access to the server via private message of the forum, or login a ticket with us. so we can pinpoint the cause of the issue quickly.
 
#5
please compare the difference of phpinfo between Litespeed and apache.

please provide access to the server via private message of the forum, or log in a ticket with us. so we can pinpoint the cause of the issue quickly.
Thank you. After comparing it, I noticed that on Apache, the allow_url_fopen is On but Litespeed, it was Off. So I turned it on and file_get_contents start working normally.

So now, how do I set the .htaccess issue? If I visit https://mysite.com/myfolders/users (without putting .php), the address won't work. But if I put it by writing like this https://mysite.com/myfolders/users.php it will work. Please, how do I make it work?
 
Last edited by a moderator:
Top