Question

I am getting the 404 error every time I am trying to get the correct URL for a product. I want to go to the specific url for that product, is there a specific magento solution to do this? I tried with addUrlRewrite and getProductUrl or getUrlPath. Nothing seems to do the trick.

Était-ce utile?

La solution

the products which have "not visible individually" are not displayed on the frontend. Its a default magento functionality.

Magento has functionality to make certain items not visible individually so you can, for example, take 6 products and turn it into 1 product where a customer can choose their options. You then hide all the individual products, leaving only that one product visible on the site and reducing duplicate content issues.

So those individual pages never actually appear on the site. They are just created to allow Magento to pull inventory on those items from that configurable product.

I would get a 404 (and if I searched for it, nothing would come up) because as far as the world outside of Magento admin is concerned, that URL doesn't exist.

Autres conseils

Not visible individually products are not displayed on the frontend by default.

but if you really want to show product here is the way

You have to override Mage_Catalog_Helper_Product goto initProduct() at line no 303 comment below the line

   if (!$this->canShow($product)) {
        return false;
    }
Licencié sous: CC-BY-SA avec attribution
Non affilié à magento.stackexchange
scroll top