Hi Guys
We are using v1.3.9h
The max display comes from:
includes/functions/extra_functions/max_display.php
It is the same kind of module as http://www.zen-cart.com/index.php?ma...roducts_id=716
Thanks for your help
Hi Guys
We are using v1.3.9h
The max display comes from:
includes/functions/extra_functions/max_display.php
It is the same kind of module as http://www.zen-cart.com/index.php?ma...roducts_id=716
Thanks for your help
in my includes/functions/extra_functions/ i do not have a max_display.php file. is that where you input the $max_results line? the instructions say to edit /includes/modules/YOUR_TEMPLATE/product_listing.php am I missing something/don't know how to read? let me know.
Thanks
Sorry, I am using an older version of this module, all thats different is the name of the files. The file in the new version is named set_num_products.php. both the new and old module use $max_display
the original code that came with the module is below:
and I am trying to turn the links into images with the following code:Code:$result .= '<a href="'.zen_href_link($page, zen_get_all_get_params(array('max_display',$listing_page_name)))."&max_display=$max_display".'">'.$step.'</a> ';
but my intention with this is:Code:if($step != '6') { $result .= '<a href="'.zen_href_link($page, zen_get_all_get_params(array('max_display',$listing_page_name)))."&max_display=$max_display".'" title="Show All Products" style="text-align:center; margin-left:40px;"><img src="includes/templates/TEMPLATENAME/images/button_showall.png" width="150" height="20" alt="Show All Products" /></a> '; } elseif($step = 'All') { $result .= '<a href="'.zen_href_link($page, zen_get_all_get_params(array('max_display',$listing_page_name)))."&max_display=$max_display".'" title="Show 6 Products" style="text-align:center; margin-left:40px;"><img src="includes/templates/TEMPLATENAME/images/button_show6.png" width="150" height="20" alt="Show 6 Products" /></a> '; } }
1. When you arrive on the page, it is displayed as 6 prods per page and only the "Show All" button is displayed plus the page navigation i.e. 1 2 3 4 [Next >>]
2. If the visitor clicks "Show All" the Image for "Show 6" is displayed
3. If the Visitor is in "Show All" Mode, then the "Show 6" Button will display
But I'm stuck. Any help much appreciated.
I understand that you are trying to put images instead of the text but how did you get it to work? how did you complete this step
Edit /includes/modules/YOUR_TEMPLATE/product_listing.php with the following code
Find:
$max_results = (PRODUCT_LISTING_LAYOUT_STYLE=='columns' && PRODUCT_LISTING_COLUMNS_PER_ROW>0) ? (PRODUCT_LISTING_COLUMNS_PER_ROW * (int)(MAX_DISPLAY_PRODUCTS_LISTING/PRODUCT_LISTING_COLUMNS_PER_ROW)) : MAX_DISPLAY_PRODUCTS_LISTING;
Replace by:
$max_results = (PRODUCT_LISTING_LAYOUT_STYLE=='columns' && PRODUCT_LISTING_COLUMNS_PER_ROW>0) ? (PRODUCT_LISTING_COLUMNS_PER_ROW * (int)($_SESSION['product_listing_max_display']/PRODUCT_LISTING_COLUMNS_PER_ROW)) : $_SESSION['product_listing_max_display'];
where did you find the $max_results line? there is no $ max_results in my Edit /includes/modules/YOUR_TEMPLATE/product_listing.php file.
I already have the following code in my override folder for product_listing.php
$max_results = (PRODUCT_LISTING_LAYOUT_STYLE=='columns' && PRODUCT_LISTING_COLUMNS_PER_ROW>0) ? (PRODUCT_LISTING_COLUMNS_PER_ROW * (int)($_SESSION['product_listing_max_display']/PRODUCT_LISTING_COLUMNS_PER_ROW)) : $_SESSION['product_listing_max_display'];
The module is working as it was intented to, but I want to change text links to images but only show the option relevant.
i.e.
if six products are displayed - show the "display all products" image only
if all products displayed - show the "display 6 products" image only
Does anybody have any ideas about this one?
All I want to do is hide the image that is dispalying that is not relevant.
i.e.
if six products are displayed - show the "display all products" image only
if all products displayed - show the "display 6 products" image only
I am not familiar with this code, but something that stands out is that you are using:
what happens if you change that to:Code:elseif($step = 'All') {
Code:elseif($step == 'All') {
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!]
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!
Version 1.3a was just uploaded
Bug Fix - Changed ADMIN CONFIG to match what was added to configuration. Post #122
Display Fix - Added existing class "back" so the links/drop-down doesn't clobber the next/previous links. Post #120
Clean Up - Cleaned up the code in Example File (/includes/templates/YOUR_TEMPLATE_NAME/templates/tpl_modules_product_listing.php) for easier merging.
You can see the DEMO & DOWNLOAD here while you wait for it to be approved.
I have downloaded the latest and the previous version of the plugin looking for the css file. It doesn't seem to be in either. Should there be a css file?