1

When I got a product and it's simple without a parent and I call ->getProductUrl() I get a url like this:

$_product->getProductUrl();

And this is giving me:

http://testdata.com/slim-fit-dobby-oxford-shirt.html

Meanwhile, a simple product with parent is returning a URL like this, which works:

http://testdata.com/french-cuff-cotton-twill-oxford-570.html

And If I try to access that url, I will get 404 page not found. Any help with this please?

0

Instead of getProductUrl() I created the whole link by: + getProductPath(). This way the linked worked, also do not forget to change the option so that the product is visible, from "Not visible individually"

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.