Jump to content

remove the extention html from product pages


Recommended Posts

Hello,

I want to migrate from woocommerce on wordpress to prestashop and I have to keep the same urls as much as I can.

I did not know how to remove ".html"

i also could not remove "info/" in the path of cms pages in SEO/URL menu.

 

PS: I installed cleanurls and it removed ids from product pages which is good.

Link to comment
Share on other sites

As far as I know, it should be enough to simply get rid of .html in the seo and urls page (urls schema tab)

 

I just tried and it works for me :)

Do you use cleanurls. because i use cleanurls to hide id from urls but when i try to remove .html i get products not found in the front

Link to comment
Share on other sites

personally I would look for solution using .htaccess rewrites, there are many examples outside of prestashop

 

here is one example you can try  NOTE: THIS IS UNTESTED

<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.html -f
RewriteRule ^(.*)$ $1.html
</IfModule>
Link to comment
Share on other sites

 

personally I would look for solution using .htaccess rewrites, there are many examples outside of prestashop

 

here is one example you can try  NOTE: THIS IS UNTESTED

<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME}\.html -f
RewriteRule ^(.*)$ $1.html
</IfModule>

It does not work. is there a plugin that can remove "/content" (not replace it by another word) and remove ".html"

Edited by bostamaster (see edit history)
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...