VirtueMart Forum

VirtueMart 2 + 3 + 4 => Templating & Layouts => Topic started by: fc338339 on April 12, 2018, 02:33:22 AM

Title: how to move "Recently Viewed Products" AFTER "Product" in category view
Post by: fc338339 on April 12, 2018, 02:33:22 AM
As subject

when click from category layout to product list , how can I switch the order

FROM
  Category Title
  Recently Viewed Products
  Product

TO
  Category Title
  Product
  Recently Viewed Products


Thanks
Fion
Title: Re: how to move "Recently Viewed Products" AFTER "Product" in category view
Post by: jenkinhill on April 12, 2018, 10:50:47 AM
http://forum.virtuemart.net/index.php?topic=128401.0
Title: Re: how to move "Recently Viewed Products" AFTER "Product" in category view
Post by: fc338339 on April 13, 2018, 16:11:44 PM
Dear Sirs,

I have two websites, so I guess adding badge method are different too

1. website P : joomla 3.8.6 + virtuemart 3.2.14
2. website A : joomla 3.6.5 + virtuemart 3.0.14  (I have make many changes on core files that I cannot upgrade neither joomla nor virtuemart)

Thanks for your help

Fion
Title: Re: how to move "Recently Viewed Products" AFTER "Product" in category view
Post by: Studio 42 on April 14, 2018, 19:12:39 PM
The problem is that now Virtuemart dont let the choice to ivert it in template or use another layout.
All the types are in a big array in this order:
featured discontinued latest topten recent products
If you want to change it, you have to do an override in your template.
If you use
$this->products = array_reverse($this->products);
You have the main products first in this order
products recent topten latest discontinued featured
products is the main list