News:

Support the VirtueMart project and become a member

Main Menu

display all categories and products on the front page

Started by mcarazzo, March 30, 2016, 05:02:27 AM

Previous topic - Next topic

mcarazzo

Hi
Im just working on a very simple site.

I need to create a single page where I can display all the categories and all the products inside each category. I have just 6 categories and 3 products in each one.

I could find a good way to do that. Should I modify the view or try installing a module?

Also each product should have the link to be added into the cart.

Regards


Studio 42

The simples way to add all product in main page  is to use a main category and add all product in this category.
eg.
MAINCAT <- all product in this category
-subcat1 3 products
-subcat2 3 products
...
And add a menu link to this main category

mcarazzo

Thanks for your answer.

I mean that I want to display all categories and all products there. Also I can create a new view if it is the best scenario.
Something like this:

Category 1
     Product 1.1 (Link to add to cart)
     Product 1.2 (Link to add to cart)
     Product 1.3 (Link to add to cart)
Category 2
     Product 2.1 (Link to add to cart)
Category 3
     Product 3.1 (Link to add to cart)
     Product 3.2 (Link to add to cart)


And a button to checkout in a modal window.

Thanks!

Studio 42

This need then to redo a loop for subcategories and get product in this categories.
The code is too long to write, but you can use an existing category layout and modify it for your needs and force this in your menu link.