Answer the question
In order to leave comments, you need to log in
How to remove index.php inside url?
Need to get rid of index.php inside url.
The structure is the following:
domain.com/index.php/catalog/
the catalog section exists and opens, but I can't get rid of index.php, since all the information I found comes down to a redirect with index.php at the end. Can you recommend something?
Answer the question
In order to leave comments, you need to log in
RewriteCond %{REQUEST_URI} ^(.*)/index\.php$
# URL cодержит index.php в конце.
RewriteCond %{REQUEST_METHOD} =GET
# Выявляем GET запрос в URL (не POST).
RewriteRule ^(.*)$ %1/ [R=301,L]
# Удалить index.php из URL.
If you have apache, you can use mod_rewrite.
Here is the first article that came across with a description: https://habr.com/en/post/83597/
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question