News:

Looking for documentation? Take a look on our wiki

Main Menu

Costumising/creating viewed products

Started by ioncap, February 26, 2016, 12:55:22 PM

Previous topic - Next topic

ioncap

Hello dear people,

Since a few days i am working on this site for a client, and to be honest i had never heard of VirtueMart before the start of this week.
So i am pretty new to this, and i am enjoying customizing the site a lot!

Though i have a little problem, since the client has some specific wishes concerning a "viewed products" functionality.
What the client has: a site for some years now, though the link will direct to a mirror of the site for testing purposes.
The products are listed and as can be seen the products have a simple layout (as does the whole site, not my idea but client is king).

What the client wants: A colored border or a transparent overlay on the products that has been visited by the site visitors (which are stored in the session i figured).

I've been looking into a lot of source files the couple few days but i can't seem to figure out where to add this functionality.
My idea would be to check if the href or whatsoever of the products correspond with what is stored in the session to assign a extra class to the individual products in case this check would output a positive/true.

Perhaps i only need to figure in what file the products are being obtained from the db and the different classes are being assigned.

I hope my problem is clear, thank you kindly for taking the time to read this!

FYI:
Joomla!        v: 3.4.1
Virtuemart    v: 3.0.8

Kind regards
-Ioncap

Ghost

#1
First, update Joomla and VirtueMart to latest stable version. Your current Joomla version has a serious vulnerability.

Assuming you want to show this in category (i.e. product list) pages, create an override of /components/com_virtuemart/sublayouts/products.php (place it in /templates/yourtemplate/html/com_virtuemart/sublayouts).

http://docs.virtuemart.net/tutorials/templating-layouts/199-sublayouts.html

The rest is correct.

ioncap

Quote from: Ghost on February 26, 2016, 13:15:08 PM
First, update Joomla and VirtueMart to latest stable version. Your current Joomla version has a serious vulnerability.

Assuming you want to show this in category (i.e. product list) pages, create an override of /components/com_virtuemart/sublayouts/products.php (place it in /templates/yourtemplate/html/com_virtuemart/sublayouts).

http://docs.virtuemart.net/tutorials/templating-layouts/199-sublayouts.html

The rest is correct.

Thank you kindly Ghost for this quick reply and heads-up concerning the vulnerability.

Kind regards,
-Ioncap