Jump to content
  • Checkout
  • Login
  • Get in touch


The e-commerce.

STS Clickable Product images

Recommended Posts

Nevermind, figured it out, heres the answer for future reference:


In includes/sts_product_info.php


Find line: (45)

  $template['imagelarge'] = tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), '','','');


Replace with:

$template['imageformlarge'] = '<a href="javascript:popupWindow(\\\'' . tep_href_link(FILENAME_POPUP_IMAGE, 'pID=' . $product_info['products_id'] . '&invis=0') . '\\\')">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], addslashes($product_info['products_name']), 'hspace="5" vspace="5"') . '<br>' . TEXT_CLICK_TO_ENLARGE . '</a>';
$template['imagelarge'] = '<a href="' . tep_href_link(DIR_WS_IMAGES . $product_info['products_image']) . '" target="_blank">' . tep_image(DIR_WS_IMAGES . $product_info['products_image'], $product_info['products_name'], 'hspace="5" vspace="5"') . '<br>' . TEXT_CLICK_TO_ENLARGE . '</a>';


And in includes/sts_templates/product_info.php.html


Insert the follow to display clickable large image:

<script language="javascript"><!--
                                 <p align="center">$imagelarge</noscript>



This same approach can be used for different sized images etc... (i'm too lazy to paste all)

Edited by dave111
Link to comment
Share on other sites

  • 4 months later...

I know this is an old post, but hopefully you can answer this for me. I've taken over an existing site and I've been going through trying to determine what mods have been installed and why certain things do not work properly.


This is one issue I've encountered. The large image popups do not work. The person that created the site originally installed STS, version 2.01. There is only one template file, sts_template.html.


I modified, per your post here sts_product_info.php but this did not fix the issue. (site can be seen at http://newsneaker.com) I see a java error in the tray below when clicking on the larger images. There is no template directory or files created other than the one I mentioned above, thus no product_info template to modify.


I've not used STS in the past, so I'm trying to quickly come up to speed on this. The plan is to tear this apart as there are many issues and rebuild, but right now I'm just trying to fix broken issues. I'm wondering if it would be worth while to upgrade to the more current version of STS (in view of the fact I will be rebuilding soon), and if so would this possibly fix this issue.


I've also just installed Webmaker's Header Tag Controller on my local test version and am finding issues there, but I'll post questions regarding that in a more appropriate thread.


Thanks for any insight you might provide.


Ruth in AZ

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...