Jump to content

PrestaShop hide product attributes values in the URL


Edge_jr
 Share

Recommended Posts

On 12/23/2020 at 3:39 PM, edge82 said:

Hi,

I want to know how to hide product attributes values in the URL

For example

URL with product attributes values => https://www.mydomain.com/men/1-1-hummingbird-printed-t-shirt.html#/1-size-s/8-color-white

New URL => https://www.mydomain.com/men/1-1-hummingbird-printed-t-shirt.html

Please help and advise.

Hi,

 

has you find a solution?

i have the same problem. 

Share this post


Link to post
Share on other sites

On 12/23/2020 at 11:55 PM, Zohaib-fk said:

You need to search keyword name "getAnchor" in file location /ps7rootfolder/classes/Link.php

Update code like below, need to comment $anchor variable.

//$anchor = $ipa ? $product->getAnchor((int) $ipa, (bool) $addAnchor) : '';
$anchor = '';

The working example can be seen at the URL => https://www.hrms-systems.com/presta-addons/en/

 

Many thanks for the support.

The problem is solved on ps 1.7

 

Share this post


Link to post
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
 Share

×
×
  • Create New...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More