Developer forum

Forum » Ecommerce - Standard features » Dublicate products when using root path

Dublicate products when using root path

Martin Ottesen
Martin Ottesen
Reply

Hi DW, 

My goal is to achieve product urls without product categories. Which I have achieved in the picture below, by using root path on my details page.

 

The issue now is that, because the product has a lot of related groups, I get equally as many products with -1, -2, -3... -23 at the end, even when i have chosen a primary group.

This is the product displayed: https://swift-staging.goecker.dk/aputure-mc-mini-led-cri-96-23 which is number 23 of its kind.

I'd love to get clean urls without and -x at the end.

 


Replies

 
Nicolai Pedersen
Reply

I cannot see all those other urls:

https://swift-staging.goecker.dk/?showurlindex=true

Did you happen to have the URL providers enabled also?

 
Martin Ottesen
Martin Ottesen
Reply

Hi Nicolai,

If I search for the product (aputure-mc-mini-led-cri-96) in the link that you've sent, I see 24 entries.

The only thing i have enabled is this on the details page.

 

 

 
Nicolai Pedersen
Reply

Ah - -23 was the counter!! Will look further into this.

 
Martin Ottesen
Martin Ottesen
Reply

Oh yes hah :)

That sounds good, thank you Nicolai!

 
Nicolai Pedersen
Reply

Hi Martin

I have looked into the code and this is done on purpose to ensure that all links to the product can be used - i.e. &groupid=1&productid=1, &groupid=2&productid=1 etc.

Rendering will usually take care of ensuring only to use the primary groupid - and add a canonical using the primary groupid if one of the other URLs are used. Normally this behavior will create urls like /group1/product and /group2/product - in your case of course different since all product names are placed in the root and the URL cannot be unique without the group as part of it.

The only way to change this is to create a new setting on the provider to only load the product once - using the primary (or first/random) group in the relations. That would cause only &groupid=1&productid=1 to be resolved and not &groupid=2&productid=1 - so implementation would have to take this into account.

I guess that would be your whish?

BR Nicolai

 
Martin Ottesen
Martin Ottesen
Reply

Hi Nicolai,

A setting like that would be greatly appreciated, that way we could keep our URLs clean without having to tamper with any templates. And yes, if no primary group would be selected then it should just be random, as it doesn't really make any difference to the url.

 
Martin Ottesen
Martin Ottesen
Reply

Hi Nicolai,

What would the timeline be to get a setting like this implemented?

 
Martin Ottesen
Martin Ottesen
Reply

Bump :)

 
Martin Ottesen
Martin Ottesen
Reply

Hi DW, 

Does this have any updates or has it been registered as a bug?

We still have customers where is an issue, because we get a lot more URLs on each product than we want.

 
Nicolai Pedersen Dynamicweb Employee
Nicolai Pedersen
Reply

Neither, nor will it be...

 
Anders Ebdrup
Anders Ebdrup
Reply

Dear Nicolai,

 

Will this be added in the near future to support the request?

 

Best regards, Anders

 
Martin Ottesen
Martin Ottesen
Reply

Hi Nicolai, 

As Anders Asks, will this at any point be added to support this request of being able to just use the primary group for the URL and then not create additional URLs for the related groups?

BR 

Martin

 

You must be logged in to post in the forum