The documentation now describes how to do this for new, all, featured and product listing pages.
http://www.thatsoftwareguy.com/zenca...scription.html
The documentation now describes how to do this for new, all, featured and product listing pages.
http://www.thatsoftwareguy.com/zenca...scription.html
That Software Guy. My Store: Zen Cart Support
Available for hire - See my ad in Services
Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
Do you benefit from Zen Cart? Then please support the project.
Hi,
I followed the instructions of swguy on
http://www.thatsoftwareguy.com/zenca...scription.html,
and it works fine for the featured-, new-, and all product pages.
But it won't show up in the product listing pages.
I just see my 'boilerplate strings'
Any clues?
Thanks, anna
Remember that includes/modules/product_listing.php is a template file - so if you've overridden it in includes/modules/<your template>/product_listing.php, then this is the file you want to edit.
That Software Guy. My Store: Zen Cart Support
Available for hire - See my ad in Services
Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
Do you benefit from Zen Cart? Then please support the project.
that was it, thank you so much for all your help.
regards, anna
this is really cool, thanks swguy, I have found a little quirk though, which caused me a little problem.
Now I've found a solution, I'll post incase anyone else comes across the same issue.
I have quite a few categories with only one product in them, when this snippet was installed, the category would appear but clicking on it took you to a totally blank page.
It seems zen didn't like the extra defines file when theres only one product in a category.
To fix this I placed the defines code supplied by swguy in another extra defines file, I used document_general.php, its only got one other define in it.
This seems to have fixed my error, hope this helps someone else
![]()
Best to just create an extra_defines file especially for this; no need to overload the document file. Thanks for this catch.
That Software Guy. My Store: Zen Cart Support
Available for hire - See my ad in Services
Plugin Moderator, Documentation Curator, Chief Cook and Bottle-Washer.
Do you benefit from Zen Cart? Then please support the project.
Hi SWguy,
I have followed your directions and the boilerplate is still not showing up on the product description. I'm trying to add this to category ID 39. It seems so simple.. what am I doing wrong?
Here is the code from override tpl_product_info_display.php:
and here is the code for my_defines.php:Code:<?php if (($products_description != '') || ($current_category_id == 39) ) { ?> <div id="productDescription" class="productGeneral biggerText"> <?php $stripped_products_description = $products_description; if ($current_category_id == 39) { $stripped_products_description = $stripped_products_description . CAT39_DESC; } echo stripslashes($stripped_products_description); echo '</div>'; ?> <?php } ?>
Thank you for your help!Code:<?php $descr_stringlist = array("CAT39_DESC", "CAT40_DESC"); define('CAT39_DESC', '10 Percent Rebate for xxxxx<br>You will receive your refund within 7 days. If you have any questions, please contact us.'); ?>