Magento - 404 error in public product page

≡放荡痞女 提交于 2019-12-05 10:28:13
Nerjuz

Go to your DB and run this SQL query:

INSERT INTO `report_event_types` (`event_type_id`, `event_name`, `customer_login`) VALUES
(1, 'catalog_product_view', 1),
(2, 'sendfriend_product', 1),
(3, 'catalog_product_compare_add_product', 1),
(4, 'checkout_cart_add_product', 1),
(5, 'wishlist_add_product', 1),
(6, 'wishlist_share', 1);

P.S. check DB name prefix if you have it!

Yervand Abrahamyan

Go to Mage\Catalog\controllers\ProductController.php and change viewAction() actions code:

from (line 140)

} else {
     Mage::logException($e);
     $this->_forward('noRoute');
}

to

} else {
    echo "<pre>";
    var_dump($e);
    Mage::logException($e);
    //$this->_forward('noRoute');
}

Then load product view, you can see the exception variable(in my case it was missing block, so I deleted it from one of layout .xml file). After finding the reason, you must restore code of viewAction().

Go to catalog > URL Rewrite Management and search the url you are having problems.

delete the rule that it is generating the problem

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!