VirtueMart Forum

VirtueMart Dev/Coding Central: VM1 (old version) => Virtuemart 1.1 Development (Archiv) => Quality & Testing VirtueMart 1.1.x => Topic started by: doorknob on March 02, 2008, 15:29:44 PM

Title: Recently Viewed Products Template problem (and fix)
Post by: doorknob on March 02, 2008, 15:29:44 PM
The recently viewed products facility in VM 1.1 (Nightly 02/03/2008) uses a hard-coded template name.
This can be fixed by making the following change:
administrator\components\com_virtuemart\classes\ps_product.php
Change line 2510 from
return $tpl->fetch( 'common/recent.tpl.php' );

to
return $tpl->fetch( $this->tpl_name );

and insert the following after line 27
public $tpl_name = 'common/recent.tpl.php';

This will allow the name of the file to be changed after the object has been instantiated but before the code is executed.

Regards
Phil