If this is your first visit, check our documentation. To post, register or login.

subcategory image

Started by kelleymotorsports on 5 Dec 2012, 2:57 AM · Views: 1,242

Results 1 to 13 of 13
5 Dec 2012, 2:57 AM
#1
kelleymotorsports avatar

kelleymotorsports

New Zenner

Join Date:
Jul 2012
Posts:
58
Plugin Contributions:
0

Post #1 by kelleymotorsports

on our site https://www.kelleymotorsports.com if you go to Parts > Hisun 700 you will see the parts sections. i added a picture to the category "Shift Shaft Assembly" and what i want it to do is actually show after on click on that category.

so you click shift shaft assembly and when the section loads, that picture would show up at the top as a parts diagram for the parts listed in the category. maybe i am not explaining this right but hopefully someone can understand. i just want it there for reference and then they can scroll down to select their part(s)

5 Dec 2012, 4:56 PM
#2
ajeh avatar

ajeh

Oba-san

Join Date:
Sep 2003
Location:
Ohio
Posts:
62,757
Plugin Contributions:
1

Post #2 by ajeh

Check your settings in the Configuration ... Product Listing ... for the:

Include Product Listing Sub Categories Image
Do you want to include the Sub Categories Image on the Product Listing?

true
false

make sure it is turned on ...

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!

5 Dec 2012, 5:27 PM
#3
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,874
Plugin Contributions:
8

Post #3 by gjh42

I expect you want a large image for the parts diagram, and having that as the category's official image would mean loading a big file for a thumbnail image of the category in category listing pages. It might work better to turn off the "show category image" and just put the big parts diagram image into the category description. Then you can use a small file for the thumbnail if you want.

5 Dec 2012, 5:38 PM
#4
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,874
Plugin Contributions:
8

Post #4 by gjh42

I suspect your Template Monster template may be restricting what can display in the product listing page. The "Property categories:" is something I have seen on other TM templates, and not part of stock ZC. TM must somehow have hard-coded it into the template file. Find where that is (possibly /includes/templates/your_template/templates/tpl_modules_product_listing.php) and you may see what else they have done.

21 Jan 2013, 3:38 PM
#5
kelleymotorsports avatar

kelleymotorsports

New Zenner

Join Date:
Jul 2012
Posts:
58
Plugin Contributions:
0

Post #5 by kelleymotorsports

i'm looking but am terrible at code. anything you see that i dont.

<?php /** * Module Template * * @package templateSystem * @copyright Copyright 2003-2005 Zen Cart Development Team * @copyright Portions Copyright 2003 osCommerce * @license <http://www.zen-cart.com/license/2_0.txt> GNU Public License V2.0 * @version $Id: tpl_modules_product_listing.php 3241 2006-03-22 04:27:27Z ajeh $ */ include(DIR_WS_MODULES . zen_get_module_directory(FILENAME_PRODUCT_LISTING)); ?> <div id="productListing"> <?php if ( ($listing_split->number_of_rows > 0) && ( (PREV_NEXT_BAR_LOCATION == '1') || (PREV_NEXT_BAR_LOCATION == '3') ) ) { ?> <div id="productsListingListingTopLinks" class="navSplitPagesLinks forward"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, zen_get_all_get_params(array('page', 'info', 'x', 'y', 'main_page'))); ?></div> <div id="productsListingTopNumber" class="navSplitPagesResult fleft"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></div> <br class="clearBoth" /> <?php } ?> <div class="tie tie-margin1"> <div class="tie-indent">
	<?php
	// only show when there is something to submit and enabled
		if ($show_top_submit_button == true) {
	?>
	<div class="buttonRow forward"><?php echo zen_image_submit(BUTTON_IMAGE_ADD_PRODUCTS_TO_CART, BUTTON_ADD_PRODUCTS_TO_CART_ALT, 'id="submit1" name="submit1"'); ?></div>
	<br class="clearBoth" />
	<?php
		} // show top submit
	?>
	
	
	<?php
	/**
	 * load the list_box_content template to display the products
	 */
	  require($template->get_template_dir('tpl_tabular_display.php',DIR_WS_TEMPLATE, $current_page_base,'common'). '/tpl_tabular_display.php');
	?>
	
	
	<?php
	// only show when there is something to submit and enabled
		if ($show_bottom_submit_button == true) {
	?>
	<div class="buttonRow forward"><?php echo zen_image_submit(BUTTON_IMAGE_ADD_PRODUCTS_TO_CART, BUTTON_ADD_PRODUCTS_TO_CART_ALT, 'id="submit2" name="submit1"'); ?></div>
	<br class="clearBoth" />
	<?php
		} // show_bottom_submit_button
	?>
</div> <?php // if ($show_top_submit_button == true or $show_bottom_submit_button == true or (PRODUCT_LISTING_MULTIPLE_ADD_TO_CART != 0 and $show_submit == true and $listing_split->number_of_rows > 0)) { if ($show_top_submit_button == true or $show_bottom_submit_button == true) { ?> </form> <?php } ?> <div class="clear"></div> </div> </div> <?php if ( ($listing_split->number_of_rows > 0) && ((PREV_NEXT_BAR_LOCATION == '2') || (PREV_NEXT_BAR_LOCATION == '3')) ) { ?> <div id="productsListingBottomNumber" class="navSplitPagesResult back"><?php echo $listing_split->display_count(TEXT_DISPLAY_NUMBER_OF_PRODUCTS); ?></div> <div id="productsListingListingBottomLinks" class="navSplitPagesLinks forward"><?php echo TEXT_RESULT_PAGE . ' ' . $listing_split->display_links(MAX_DISPLAY_PAGE_LINKS, zen_get_all_get_params(array('page', 'info', 'x', 'y'))); ?></div> <br class="clearBoth" /> <?php } ?>
21 Jan 2013, 3:40 PM
#6
kelleymotorsports avatar

kelleymotorsports

New Zenner

Join Date:
Jul 2012
Posts:
58
Plugin Contributions:
0

Post #6 by kelleymotorsports

gjh42:

I expect you want a large image for the parts diagram, and having that as the category's official image would mean loading a big file for a thumbnail image of the category in category listing pages. It might work better to turn off the "show category image" and just put the big parts diagram image into the category description. Then you can use a small file for the thumbnail if you want.

the file i want will not be large in file size just large enough to see the picture is all.

21 Jan 2013, 4:39 PM
#9
kelleymotorsports avatar

kelleymotorsports

New Zenner

Join Date:
Jul 2012
Posts:
58
Plugin Contributions:
0

Post #9 by kelleymotorsports

theres more to the file but i'm assuming it has something to do with this section?

<?php /** * Page Template * * Loaded by main_page=index<br /> * Displays product-listing when a particular category/subcategory is selected for browsing * * @package templateSystem * @copyright Copyright 2003-2007 Zen Cart Development Team * @copyright Portions Copyright 2003 osCommerce * @license <http://www.zen-cart.com/license/2_0.txt> GNU Public License V2.0 * @version $Id: tpl_index_product_list.php 6009 2007-03-13 23:56:45Z ajeh $ */ ?> <div class="centerColumn" id="indexProductList"> <h1 id="productListHeading"><?php echo $breadcrumb->last(); ?></h1> <?php if ( (PRODUCT_LIST_CATEGORIES_IMAGE_STATUS == 'true' && $categories_image = zen_get_categories_image($current_category_id)) || $current_categories_description != '') { ?> <div class="tie3 text2 tie-margin1"> <div class="tie3-indent"> <strong>Property categories:</strong> <div class="wrapper" id="indexProductListCatDescription">
<?php
if (PRODUCT_LIST_CATEGORIES_IMAGE_STATUS == 'true') {
// categories_image
  if ($categories_image = zen_get_categories_image($current_category_id)) {
?>
<?php /*
	<div id="categoryImgListing" class="categoryImg"><?php echo zen_image(DIR_WS_IMAGES . $categories_image, '', CATEGORY_ICON_IMAGE_WIDTH, CATEGORY_ICON_IMAGE_HEIGHT); ?></div>
*/?>
<?php
  }
} // categories_image
?>

<?php
// categories_description
	if ($current_categories_description != '') {
?>
<div class="content_desc"> <?php echo $current_categories_description;  ?> </div>
<?php } // categories_description ?>
</div>
</div>
</div>
23 Jan 2013, 8:21 PM
#10
gjh42 avatar

gjh42

Black Belt

Join Date:
Jul 2005
Location:
Upstate NY
Posts:
21,874
Plugin Contributions:
8

Post #10 by gjh42

<?php /*
<div id="categoryImgListing" class="categoryImg"><?php echo zen_image(DIR_WS_IMAGES . $categories_image, '', CATEGORY_ICON_IMAGE_WIDTH, CATEGORY_ICON_IMAGE_HEIGHT); ?></div>
*/?>
``` The /* and */ are commenting out the category image, preventing it from displaying no matter what you set in admin. This is shoddy template design, deciding for the user what they will be allowed to do.
Remove the <?php /* and */?> and you will see the image.
24 Jan 2013, 2:25 AM
#11
kelleymotorsports avatar

kelleymotorsports

New Zenner

Join Date:
Jul 2012
Posts:
58
Plugin Contributions:
0

Post #11 by kelleymotorsports

amazing! thank you soooo much!!!

now one last question on this... is there any way to remove the sub category image when you are viewing the product details? it stays the same 500x500 like the product listing page. if not thats ok i can deal with it but if there is a way that would be sweet!. or should i keep it for customers to refer to again? thoughts are also appreciated. now if someone could possibly help with my sale items with attributes not showing sale price when added to the cart i would be set!!

24 Jan 2013, 2:46 AM
#13
kelleymotorsports avatar

kelleymotorsports

New Zenner

Join Date:
Jul 2012
Posts:
58
Plugin Contributions:
0

Post #13 by kelleymotorsports

and again, thank you! if you have any input on the tires not showing the sale price in the cart let me know.
:D:D:D:D:D:D:D