Answer the question
In order to leave comments, you need to log in
If I add a slash to the end of the URL, then the server gives a 404 error, how to fix it?
There is a URL, for example, site.ru/catalog - everything is great, all links on the site lead without a slash at the end, but if you use all sorts of utm tags, there is a slash before the "?" sign, and when you open the link site.ru/catalog / - the generated CMS 404 error falls out.
How to add to .htaccess (or not in it?) so that the slash also works?
Will a simple redirect (in an ad with a slash, and we redirect to "without a slash") not have a bad effect on advertising campaigns?
What's in .htaccess now:
RewriteBase /
RewriteRule ^в_наличии$ index.php?route=product/special [L]
RewriteRule ^sitemap.xml$ index.php?route=feed/google_sitemap [L]
RewriteRule ^googlebase.xml$ index.php?route=feed/google_base [L]
RewriteRule ^download/(.*) /index.php?route=error/not_found [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !.*\.(ico|gif|jpg|jpeg|png|js|css)
RewriteRule ^([^?]*) index.php?_route_=$1 [L,QSA]
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question