Magento Forum

   
Redirect HomePage
 
focusnet
Jr. Member
 
Total Posts:  5
Joined:  2008-06-13
 

Hello

In the admin there’s an option where i can define the cms-page that shows on homepage. But i want directly display a category on the shop-homepage. How can I redirect the root to the category.

Example: Redirect “/” to Category “/test” with the category ID 123.

It works with e meta refresh - but thats no e good solution grin

Thank you for your help.

Raffi

 
Magento Community Magento Community
Magento Community
Magento Community
 
mike222
Member
 
Total Posts:  41
Joined:  2008-04-07
Austria
 

Enter the following code in your cms - page:

{{block type="catalog/product_list" category_id="2" template="catalog/product/list.phtml"}}

change the category_id as appropriate.

regards,

Mike

 
Magento Community Magento Community
Magento Community
Magento Community
 
focusnet
Jr. Member
 
Total Posts:  5
Joined:  2008-06-13
 

Thank you...that i have alredy tested...but in my shop i will show not products on the homepage i want to show subcategories of a main category. When i put your code to the CMS page i get the following error:
Fatal error: Call to a member function getMetaTitle() on a non-object in
.......app\code\core\Mage\Catalog\Block\Category\View.php on line 37

After that error i want a work around with e redirect directly to the category.

 
Magento Community Magento Community
Magento Community
Magento Community
Magento Community
Magento Community
    Back to top