Linked images just open on a new page

Jboo - August 24, 2008 - 22:48
Project:FancyZoom
Version:6.x-1.0
Component:Code
Category:bug report
Priority:normal
Assigned:slurslee
Status:fixed
Description

Hi,

I've installed the module, but when I add an image and place a link in a node to it, all that happens is that the image page loads when clicking on the link. I can't seem to get the module to work like it should.

Other than activate the module, might there be something I've missed?

Thanks for your help.

#1

mattmm - October 8, 2008 - 21:01

I get the same thing. Mod enabled, image uploaded, click and just loads the straight image.

#2

yakuza-fs - November 16, 2008 - 08:50

Same for me. I have this module enabled and the following html code in my node content:

<a href="/rgames/sites/default/files/DSC_2246.JPG">Internal Image</a>
<a href="http://k.img.com.ua/img/forall/a/6484/61.jpg">External Image</a>

Unfortunately FancyZoom doesn't work for these links. I thought there was a conflict between FancyZoom and External Links so I have disabled the last one but nothing changed.

#3

stevenkwy - February 24, 2009 - 15:25

I can't get it work as well, but my file system setting is set to private, haven't tested the public one.

#4

lostnote - March 11, 2009 - 20:46

Same here. I'm using Drupal 5.5 and have the module installed and enabled and it still doesn't work. When using the original source files rather than the module for FancyZoom, it worked fine in Firefox 3.0.7, but not in IE 7. Hope someone figures out soon.

#5

lostnote - March 12, 2009 - 17:16

After some tweaking, I was finally able to get FancyZoom to work in IE 7. Though I am not using the FancyZoom module, and am instead using the original source files, this may help someone figure out why FancyZoom may not be working within Drupal. In order for FancyZoom to work, you have to call two scripts in the of the page. They are:

Then, in the tag you have to put the following:

onLoad="setupZoom()"

In Drupal, the end result will probably look something like this:

I was trying to add this feature to a user profile page (user_profile.tpl.php) and so placed these things in the script for that page. This worked fine in Firefox 3, as most things usually do, but was not working at all in IE 7, as most things usually don't. When I clicked on an image link in IE, I was taken to a new page where the image was loaded in the browser. IE was completely ignoring the script. After experimenting, I found that if I placed these three bits of code in the page.tpl.php script rather than the user_profile.tpl.php script, FancyZoom would work in IE 7. Granted, there is still the issue of IE not displaying the image shadow and positioning the close graphic incorrectly, but at least the feature works. Hopefully, this will be of some use to others.

Again, I'm using Drupal 5.5 and have tested this with Firefox 3.0.7 and IE 7.

#6

mailleux - November 8, 2009 - 02:28

I tried the onload at the body tag and in the image. And not of them worked. How do you get this module to work?

#7

slurslee - November 13, 2009 - 22:57
Assigned to:Anonymous» slurslee

I'm not sure what's happening there. Have you got JQuery Update installed? Not sure if that will help. Otherwise, can you send me a link to a page on your site where it should be working so I can take a look at it? I don't seem to be getting notifications from this issue queue, so try writing to me through the contact form on my website at http://www.thinkyhead.com/support

#8

slurslee - November 16, 2009 - 10:59
Component:Miscellaneous» Code
Category:support request» bug report
Status:active» fixed

Version 1.2 was released today. This was a bug scrub using Cabel Sasser's latest code as reference to make sure things are copacetic. The JQuery version was likewise scrubbed. Check them out and if things look good this issue will be closed. Drupal 5 users will have to wait another day for the 5.x-1.2 release.

#9

slurslee - November 16, 2009 - 11:00
Title:Can't seem to get this to work» Linked images just open on a new page
 
 

Drupal is a registered trademark of Dries Buytaert.