简体   繁体   English

joomla的IE9云缩放插件扩展上的图像放大镜问题

[英]Image magnifier issue on IE9 cloud zoom plugin extension for joomla

I have been using a plugin for joomla name cloud zoom, it's a plugin that provides our gallery the capability to create an image magnify effect when you hover over the large image on this link http://intangible-logic.com/amclassic/en/products/road-wheels/road-tubeless it works perfectly on almost all browser but in IE9 the issue is it could not able to view the full image when you move the cursor to the right side of the image it would not able to move to the edge of it same when you move it down. 我一直在使用用于joomla名称云缩放的插件,当您将鼠标悬停在此链接上的大图像上时,该插件可为我们的画廊提供创建图像放大效果的功能。http://intangible-logic.com/amclassic/zh-CN / products / road-wheels / road-tubeless在几乎所有浏览器上都可以完美运行,但是在IE9中,问题是当您将光标移到图像的右侧时,它无法查看完整图像向下移动时,将其移到相同的边缘。 I think that this was a javascript issue but don't know where to begin with. 我认为这是一个JavaScript问题,但不知道从哪里开始。

Thanks Christopher Pelayo for pointing me in the right direction. 感谢Christopher Pelayo为我指出正确的方向。 However, I think it's better to change 但是,我认为最好改变

cw = (sImg.outerWidth() / zoomImage.width) * zoomDiv.width();
ch = (sImg.outerHeight() / zoomImage.height) * zoomDiv.height();

to

cw = (sImg.outerWidth() / zoomImage.width) * zoomDiv.outerWidth();
ch = (sImg.outerHeight() / zoomImage.height) * zoomDiv.outerHeight();

after a few hours of tracing the code I just found the problem: 在跟踪代码几个小时之后,我才发现问题所在:

somewhere around line 277 of the file named cloud-zoom.1.0.2.js you'll find this code: 在名为cloud-zoom.1.0.2.js的文件的第277行附近的位置,您会找到以下代码:

cw = (sImg.outerWidth() / zoomImage.width) * zoomDiv.width();

the line for the zoomDiv.width() is returning the wrong value but this only occurs on IE9 browser so what I did is update this code to solve the problem: zoomDiv.width()的行返回了错误的值,但这仅在IE9浏览器上发生,所以我要做的是更新此代码来解决问题:

cw = (sImg.outerWidth() / zoomImage.width) * sImg.outerWidth();

not sure how this would affect the way the plugin works but somehow it resolves our problem in IE9 and works perfectly with all the other browsers as well. 不确定这将如何影响插件的工作方式,但可以通过某种方式解决IE9中的问题,并与所有其他浏览器完美配合。 I hope this would help anyone who encounters the same issue as I do. 我希望这将对遇到与我一样的问题的任何人有所帮助。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM