Results 1 to 3 of 3
  1. #1
    Join Date
    Feb 2010
    Posts
    15
    Plugin Contributions
    0

    image problem Set Product Listing Images to link to Image not Product Info

    What I am endeavoring to do is have the link on the Product Image in all the listing pages be linked to the image in the same way the image on the info page is.

    I am using SlimBox and from the info page I get a large overlayed example of the product image - I want to be able to do this from the listing so customers don't need to go to the info view just to get a bigger image.

    I am thinking I need to integrate this code:
    Code:
    <?php require(DIR_WS_MODULES . zen_get_module_directory(FILENAME_MAIN_PRODUCT_IMAGE)); ?> 
    <div id="productMainImage" class="centeredContent back">
    <?php
      echo '<a href="' . $products_image_large . '" title="' . $products_name . '" rel="lightbox">' . zen_image($products_image_medium, $products_name, MEDIUM_IMAGE_WIDTH, MEDIUM_IMAGE_HEIGHT) . '<br /><span class="imgLink">' . '</span></a>';
    ?>
    </div>
    into these sections of code (from Product_Listing.php)
    Code:
    Line #165 : $lc_text = '<a href="' . zen_href_link(zen_get_info_page($listing->fields['products_id']), 'cPath=' . (($_GET['manufacturers_id'] > 0 and $_GET['filter_id']) > 0 ? zen_get_generated_category_path_rev($_GET['filter_id']) : ($_GET['cPath'] > 0 ? zen_get_generated_category_path_rev($_GET['cPath']) : zen_get_generated_category_path_rev($listing->fields['master_categories_id']))) . '&products_id=' . $listing->fields['products_id']) . '">' . zen_image(DIR_WS_IMAGES . $listing->fields['products_image'], $listing->fields['products_name'], IMAGE_PRODUCT_LISTING_WIDTH, IMAGE_PRODUCT_LISTING_HEIGHT, 'class="listingProductImage"') . '</a>';
    Code:
    Line #167 : $lc_text = '<a href="' . zen_href_link(zen_get_info_page($listing->fields['products_id']), 'cPath=' . (($_GET['manufacturers_id'] > 0 and $_GET['filter_id']) > 0 ? zen_get_generated_category_path_rev($_GET['filter_id']) : ($_GET['cPath'] > 0 ? zen_get_generated_category_path_rev($_GET['cPath']) : zen_get_generated_category_path_rev($listing->fields['master_categories_id']))) . '&products_id=' . $listing->fields['products_id']) . '">' . zen_image(DIR_WS_IMAGES . $listing->fields['products_image'], $listing->fields['products_name'], IMAGE_PRODUCT_LISTING_WIDTH, IMAGE_PRODUCT_LISTING_HEIGHT, 'class="listingProductImage"') . '</a>';
    Any help would be appreciated - the shop site currently is at http://www.thestickerfamily.com.au/shop/

    Thanks,
    Scott

  2. #2
    Join Date
    Feb 2008
    Location
    Washington State
    Posts
    236
    Plugin Contributions
    0

    Default Re: Set Product Listing Images to link to Image not Product Info

    Quote Originally Posted by Ruts67 View Post
    What I am endeavoring to do is have the link on the Product Image in all the listing pages be linked to the image in the same way the image on the info page is.

    I am using SlimBox and from the info page I get a large overlayed example of the product image - I want to be able to do this from the listing so customers don't need to go to the info view just to get a bigger image.

    I am thinking I need to integrate this code:
    Code:
    <?php require(DIR_WS_MODULES . zen_get_module_directory(FILENAME_MAIN_PRODUCT_IMAGE)); ?> 
    <div id="productMainImage" class="centeredContent back">
    <?php
      echo '<a href="' . $products_image_large . '" title="' . $products_name . '" rel="lightbox">' . zen_image($products_image_medium, $products_name, MEDIUM_IMAGE_WIDTH, MEDIUM_IMAGE_HEIGHT) . '<br /><span class="imgLink">' . '</span></a>';
    ?>
    </div>
    into these sections of code (from Product_Listing.php)
    Code:
    Line #165 : $lc_text = '<a href="' . zen_href_link(zen_get_info_page($listing->fields['products_id']), 'cPath=' . (($_GET['manufacturers_id'] > 0 and $_GET['filter_id']) > 0 ? zen_get_generated_category_path_rev($_GET['filter_id']) : ($_GET['cPath'] > 0 ? zen_get_generated_category_path_rev($_GET['cPath']) : zen_get_generated_category_path_rev($listing->fields['master_categories_id']))) . '&products_id=' . $listing->fields['products_id']) . '">' . zen_image(DIR_WS_IMAGES . $listing->fields['products_image'], $listing->fields['products_name'], IMAGE_PRODUCT_LISTING_WIDTH, IMAGE_PRODUCT_LISTING_HEIGHT, 'class="listingProductImage"') . '</a>';
    Code:
    Line #167 : $lc_text = '<a href="' . zen_href_link(zen_get_info_page($listing->fields['products_id']), 'cPath=' . (($_GET['manufacturers_id'] > 0 and $_GET['filter_id']) > 0 ? zen_get_generated_category_path_rev($_GET['filter_id']) : ($_GET['cPath'] > 0 ? zen_get_generated_category_path_rev($_GET['cPath']) : zen_get_generated_category_path_rev($listing->fields['master_categories_id']))) . '&products_id=' . $listing->fields['products_id']) . '">' . zen_image(DIR_WS_IMAGES . $listing->fields['products_image'], $listing->fields['products_name'], IMAGE_PRODUCT_LISTING_WIDTH, IMAGE_PRODUCT_LISTING_HEIGHT, 'class="listingProductImage"') . '</a>';
    Any help would be appreciated - the shop site currently is at http://www.thestickerfamily.com.au/shop/

    Thanks,
    Scott
    I can't help with this question... but I LOVE your site!
    ~ jasmel : My Store Using Contributions: Wallet Theme | Simple Google | Quantity Discounts | Godaddy | FAQ's | Confirm Email Address Entry | Admin login as customer | Newsletter Subscribe | CampaingMonitor

  3. #3
    Join Date
    Feb 2010
    Posts
    15
    Plugin Contributions
    0

    Default Re: Set Product Listing Images to link to Image not Product Info

    I have tried to cut and paste a few bits - but I am still struggling to get my head around which bit of code is writing which element - any advice here - I'd really like every image link to open the image as opposed to being the same link as the product title.

 

 

Similar Threads

  1. v151 Make entire product listing box a link to product info
    By longstockings in forum General Questions
    Replies: 1
    Last Post: 23 Oct 2013, 07:52 PM
  2. v139h Product Listing and Product Info images always same size?
    By tsehov in forum Templates, Stylesheets, Page Layout
    Replies: 3
    Last Post: 23 May 2012, 06:27 PM
  3. Different image for product listing and Product Info?
    By JuanDBB in forum Basic Configuration
    Replies: 2
    Last Post: 7 Apr 2009, 09:32 PM
  4. Product description in product more info in html format but not in product listing?
    By this side up in forum Customization from the Admin
    Replies: 1
    Last Post: 18 Dec 2006, 06:25 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