How to show all the products from the same category in a product description


Avatar: laur

2012-10-07 23:05

How to show all the produsts from the same category in a product description(under the description) like the related products addon in the ext , but i want all the products in the same category to show under a products' description .

» Quick.Cart v5.x

treewood (OpenSolution)

Avatar: treewood

2012-10-09 07:52

try to use list products function.

edit actions/pages.php and check fot this code:
$sProductsList = $oProduct->listProducts( $aData['sTemplate'], $iContent, isset( $bViewAll ) ? 999 : null );

copy this code to actions/products.php near line 31 and do changes:
$sProductsList = $oProduct->listProducts( 'pages_default.tpl', array_shift( $aData['aCategories'] ), 999 );

Now you need paste $sProductsList to templates/default/products_default.tpl near $aData[sDescriptionFull] and add some style css.



Avatar: laur

2012-10-09 16:10

woow man , thank you sooo much . I only modyfied products.php and added that line $sProductsList = $oProduct->listProducts( 'pages_default.tpl', array_shift( $aData['aCategories'] ), 999 );
and added $sProductsList into products_default.tpl .
In pages.php I don't do anything , but is still working as expected !,hotjet-9w-b0-w35
Is ok ? for me looks and function allwright :P . Thank you again.
Ps . check my custom jquery google search on my site , i did it myselph :p

Back to top
about us | contact