simberak Posted December 6, 2019 Share Posted December 6, 2019 (edited) Hello to all, I would like to make new landing pages in CMS. What I would like to achieve is custom urls for my new landing pages, because now the url of cms looks like webstie.com/content/id-name-of-article. I would like the landing page url in this way: website.com/name-of-article. So can I do it through .htaccess with url redirect/remapping? I need to make this manualy for each landing page because I am already using the content/id-older-articles for older articles. So If I use the .htaccess and will remap the landing from cms like this # url remapping RewriteEngine on RewriteRule first-landing-page content/id-first-landing-page RewriteRule second-landing-page content/id-second-landing-page RewriteRule third-landing-page content/id-third-landing-page then the customer will come to website.com/first-landing-page and get the content (not redirection to) of content/id-first-landing-page. But then there will be duplicity, because both url are existing. And I want to rank my new url (website.com/first-landing-page) for SERP and want not be penalized for duplicity. So how to achieve it? 1) I thought about to make a redirection 301 from website.com/content/id-first-landing-page to website/first-landing-page. But this solution maybee will do cycling? Is there possible to merge the url remapping with redirecting so it won´t cycle? I would prefer the following option, because these articles will be newly made. They don´t need to be redirected but if this will be one only solution, I will do it . 2) Set the origin article (content/id-first-landing-page) <link rel="canonical" href="https://website.com/first-landing-page" /> so it will solve the duplicity. But the question is, how to add this code to these new landing pages cms articles? 3) Do you know how to make this another way? Still I am noob in this and I don´t have another ideas Tnak you very much for help, I hope this topic will help others who are seeking solution for this too... Edited December 6, 2019 by simberak (see edit history) Link to comment Share on other sites More sharing options...
JBW Posted December 10, 2019 Share Posted December 10, 2019 (edited) There are many modules that can remove IDs from URLs, check the addon marketplace: https://addons.prestashop.com/en/search?search_query=url Technically I guess all of them use an override of Dispatcher class. Edited December 10, 2019 by JBW (see edit history) Link to comment Share on other sites More sharing options...
simberak Posted December 16, 2019 Author Share Posted December 16, 2019 Hello, thanks for your answer. But I am not looking for removing ID, I would like to rewrite the whole url by myself (and with that i will remove the ids Link to comment Share on other sites More sharing options...
simberak Posted January 28, 2020 Author Share Posted January 28, 2020 Bump pls Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now