Results 1 to 2 of 2
  1. #1
    Join Date
    Jun 2006
    Posts
    1
    Plugin Contributions
    0

    category and sub cateogry images

    I apolgize in advance if this is somewhere in the FAQ or the Forum, but I've been looking for 2 days and can't find anything...

    When a user clicks on a cateogy, I list sub categories, and when the user clicks on a sub cateogry, I'd like for the image that I uploaded to associate with that sub category to show, as well as the descritpion that has been entered.

    I can't see a way to show the sub-category image...

    btw...I'd like the image to be a descent thumbail-sized image, and allow the user to click on that image for a larger view...

    Can somebody please help me on this one? I'm stumped...

    Thanks,
    jt

  2. #2
    Join Date
    Sep 2003
    Location
    Ohio
    Posts
    69,402
    Plugin Contributions
    6

    Default Re: category and sub cateogry images

    To display the Categories Image on the Main Page ... you would need to customize two files:

    Copy the original file:
    /includes/templates/template_default/tpl_index_product_list.php

    To your templates and overrides directory:
    /includes/templates/your_template_dir/tpl_index_product_list.php

    Change the line that I have commented to the new line below it:
    PHP Code:
    <!-- <h1 id="productListHeading"><?php echo $breadcrumb->last(); ?></h1> -->
       <h1 id="productListHeading"><?php echo zen_image(DIR_WS_IMAGES zen_get_categories_image($current_category_id), zen_get_categories_name($current_category_id), HEADING_IMAGE_WIDTHHEADING_IMAGE_HEIGHT' align="middle"' ) . '<br />' $breadcrumb->last(); ?></h1>

    Next copy the file:
    /includes/templates/template_default/tpl_index_categories.php

    To your template and overrides directory:
    /includes/templates/your_template_dir/tpl_index_categories.php

    Change the line that I have commented out to the new line below it:
    PHP Code:
    <!-- <h1 id="indexCategoriesHeading"><?php echo $breadcrumb->last(); ?></h1> -->
    <h1 id="indexCategoriesHeading"><?php echo zen_image(DIR_WS_IMAGES zen_get_categories_image($current_category_id), zen_get_categories_name($current_category_id), HEADING_IMAGE_WIDTHHEADING_IMAGE_HEIGHT' align="middle"' ) . '<br />' $breadcrumb->last(); ?></h1>
    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!

 

 

Similar Threads

  1. v151 Display images of Sub-Sub category in Main page while navigating.
    By Javier Romero in forum Templates, Stylesheets, Page Layout
    Replies: 4
    Last Post: 3 May 2013, 10:02 AM
  2. Replies: 17
    Last Post: 12 Oct 2010, 05:58 PM
  3. Category images and sub cats not showing
    By lunarc in forum Templates, Stylesheets, Page Layout
    Replies: 2
    Last Post: 4 Oct 2010, 10:46 PM
  4. Instead of text, use images in category and sub-categories?
    By Cindy2010 in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 23 May 2010, 08:45 AM
  5. Styling sub-category and main product images
    By michaelvincent in forum Templates, Stylesheets, Page Layout
    Replies: 1
    Last Post: 18 Sep 2006, 08:34 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg