Can you let me know the code for showing model number in the Recently Viewed sidebox?
Can you let me know the code for showing model number in the Recently Viewed sidebox?
Adapt the code as shown for your other sidebox ...
Linda McGrath
If you have to think ... you haven't been zenned ...
Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!
Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
Officially PayPal-Certified! Just click here
Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!
How to change the code in tpl_recently_viewed.php in template folder?
'<td><div class="recent-products-name"><a href="' . $link . '">' . zen_get_products_name($recent_product, $_SESSION['languages_id']) . '</a></div><div class="rent-products-price">' . zen_get_products_display_price($recent_product) . '</div></td>' . "\n" .
Thanks
Make sure the products_model is included in the SELECT statement then reference it in the template ...
Or, use the function to call it from the functions_lookups.php file:
Code:/* * Return any field from products or products_description table * Example: zen_products_lookup('3', 'products_date_added'); */ function zen_products_lookup($product_id, $what_field = 'products_name', $language = '') {
Linda McGrath
If you have to think ... you haven't been zenned ...
Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!
Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
Officially PayPal-Certified! Just click here
Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!
could not get it right. Can you please give the codes?
Find the variable for the products_id in the sidebox ...
Then use:
zen_products_lookup($your_products_id, 'products_model')
to get the products_model of that products_id ...
So if the sidebox is using:
$recent_product
for the products_id then use:
zen_products_lookup($recent_product, 'products_model')
something like:
'<td><div class="recent-products-name"><a href="' . $link . '">' . zen_get_products_name($recent_product, $_SESSION['languages_id']) . zen_products_lookup($recent_product, 'products_model') . '</a></div><div class="rent-products-price">' . zen_get_products_display_price($recent_product) . '</div></td>' . "\n" .
Linda McGrath
If you have to think ... you haven't been zenned ...
Did YOU buy the Zen Cart Team a cup of coffee and a donut today? Just click here to support the Zen Cart Team!!
Are you using the latest? Perhaps you've a problem that's fixed in the latest version: [Upgrade today: v1.5.5]
Officially PayPal-Certified! Just click here
Try our Zen Cart Recommended Services - Hosting, Payment and more ...
Signup for our Announcements Forums to stay up to date on important changes and updates!
Bookmarks