Forums / Templates, Stylesheets, Page Layout / "Larger Image" link not working correctly

"Larger Image" link not working correctly

Locked

Started by mack2d2 on 3 Jun 2010, 9:37 PM · Views: 981

Results 1 to 3 of 3
This thread is locked. New replies are disabled.
3 Jun 2010, 9:37 PM
#1
mack2d2 avatar

mack2d2

New Zenner

Join Date:
Jun 2010
Posts:
1
Plugin Contributions:
0

"Larger Image" link not working correctly

Using Version: Zen Cart 1.3.8a
using template: http://www.zen-cart.com/index.php?main_page=product_contrib_info&cPath=40_53&products_id=148 with slight customizations to remove some of the footer and change up the header size and background image/s.

Problem: my "larger image" link on products doesn't function appropriately. At first, it simply didn't do anything when clicked... no matter what browser was used, clicking the thumbnail or the "larger image" text link didn't do anything. In hopes of resolving the issue, I installed the Lightbox module (http://www.zen-cart.com/index.php?main_page=product_contrib_info&products_id=273), and now the links work, but in an incorrect fashion... instead of loading the larger image in a new pop-up window or in proper lightbox fashion, they follow the link into the next page and the user must hit the back button to return to the store. When I was trying to install Lightbox I got some database errors, so I used the workaround I found on the forums ("countrycharm"s post at the top of this link http://www.zen-cart.com/forum/showthread.php?p=512198#post512198)... I am unsure of when exactly the "larger image" links stopped working, but I know it is tied to something template specific because the links work fine if I switch to the default Zen Cart template.

Store with issue/s: http://www.rygaardlogging.com/rygaardstore/

Any assistance in regards to shining some light on what may be the cause of my frustrations would be greatly appreciated. Thank you in advance!

4 Jun 2010, 6:38 AM
#2
soul39 avatar

soul39

Zen Follower

Join Date:
Jul 2008
Location:
london
Posts:
167
Plugin Contributions:
0

Re: "Larger Image" link not working correctly

Hi, mack2D2,
you need to set the size that you want the large image to display, like so

may have to tweak the javascript file for the pop-up window to open at the size you want. The file you need to edit is /includes/modules/pages/product_info/jscript_main.php. In the function popupWindow(url) change width= and height= to your sizes. (You can also decide whether or not you want scrollbars by setting scrollbars=no or scrollbars=yes.) Then save the file to includes/modules/YOUR_TEMPLATE/pages/product_info/

Let us know how you get on

Soul

18 Jun 2010, 6:12 AM
#3
jaybird avatar

jaybird

New Zenner

Join Date:
Nov 2009
Posts:
33
Plugin Contributions:
0

Re: "Larger Image" link not working correctly

function popupWindow(url) {
window.open(url,'popupWindow','toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,resizable=yes,copyhistory=no,width=100,height=100,screenX=150,screenY=150,top=150,left=150')

I'm confused on the exact changes to make to this last sectin of this line for my 3 different size images: small image are 150 width, _MED 150 width, _LRG 475 width.

Version 1.3.8a

Thank you.