Open sajjadazar opened 5 years ago
I had the same problem. With that is the error message in Chrome and in Safari the message is TypeError: undefined is not an object (evaluating '$image.data('lastPos').x'). Triggered at line 94
The problem seems to be that I used a slim version of jQuery. When swicthing to the full version things work as they should
Replace lines 95 and 96 in the the magnify.js source with:
nPosX = $image.offset().left; nPosY = $image.offset().top;
@sophanox thanks for a solution but there is no issue all working fine
I was still getting the issue, thanks for the fix @sophanox
@LibbyJane what error are you getting ?
hello i'm developing a wordpress theme and when i want to use the jquery.magnify.js, it'll give me this error : Cannot read property 'x' of undefined... and i'm using jquery like this : jQuery(document).ready(function () { jQuery('img').magnify(); }
so can you help me ? thanks a lot