I am trying to figure out how to add one of the attributes in list of products (not detail). Should by something like $aList[sAttribute][1] but that doesn§t work.
Can anybody help me, please?
» Quick.Cart v2.x
Mackiee
2007-10-10 15:51
So i finally make it!
I added into file core/products.php this code:
<?php $attributes = throwAttributesLightProduct( $aList['iProduct'] ); // Get attributes for the product $aList['iCustomAttribute'] = attributes[5]; // Take Attribut id 5
?> So i can use $aList['iCustomAttribute'] in productlist template.
i get Parse error: syntax error, unexpected '[' in producst.php , when i add following code.
<?php $attributes = throwAttributesLightProduct( $aList['iProduct'] ); // Get attributes for the product $aList['iCustomAttribute'] = attributes[5]; // Take Attribut id 5
?>
Where i have to add above code in /core/producst.php ????
add only following 2 line code ? but where in producst.php file ?
$attributes = throwAttributesLightProduct( $aList['iProduct'] ); // Get attributes for the product $aList['iCustomAttribute'] = attributes[5]; // Take Attribut id 5
uzyskać Parse error: syntax error , unexpected '[' w producst.php , kiedy dodać następujący kod .
Ktoś mi pomóc
Aby przeczytać moje pytanie , Proszę korzystać z Google Translate
Gdzie mam dodać wyżej kod w /core/producst.php ????
tylko dodać po 2 kod linii ? ale gdzie w producst.php pliku?
<?phphttp://opensolution.org/forum/?iTopic=4527# $attributes = throwAttributesLightProduct( $aList['iProduct'] ); // Get attributes for the product $aList['iCustomAttribute'] = attributes[5]; // Take Attribut id 5 ?>