Hello everyone, I need help with redirect issues. As of now, there are 3 files for my site and I encounter problem when I try to redirect products and about into /products and /about-us but everything works fine when I redirect index into /
All 3 files are in same directory which is inside htdocs folder. I have tried to use htaccess script and redirect functions in control panel of infinityfree but no success.
Right now, you have .htaccess rules that redirect people from /products.html to /products. However, there is no file or directory named /products, and no code to route it to another file. So the server doesn’t have any code to handle /products.
If my assumptions are correct, you want people to see the page /products.html but use the URL /products? If so, then you’ll probably want an extra .htaccess line which looks something like this (untested):
RewriteRule ^products$ /products.html [NC,L]
Alternatively, there are .htaccess snippets which remove the file extension for all files all at once. Something like this: