jQuery: The Write Less, Do More JavaScript Library

Ticket #2831 (new bug)

Opened 3 days ago

event.blind.js effect will trigger script error in IE7

Reported by: cyberflohr Assigned to: paul
Type: bug Priority: minor
Milestone: 1.2.4 Component: ui
Version: 1.2.3 Keywords:
Cc: Needs: Review

Description

I've tracked down the problem to the following lines of code within the effect.core.js script

The following lines within the createWrapper function will produce under certain circumstances NaN values for top & left.

var top = parseInt(el.css('top'), 10); if (top.constructor != Number) top = 'auto';
var left = parseInt(el.css('left'), 10); if (left.constructor != Number) left = 'auto';

fix:

var top = parseInt(el.css('top'), 10); if (isNaN(top)) top = 'auto';
var left = parseInt(el.css('left'), 10); if (isNaN(left)) left = 'auto';

Attachments

Note: See TracTickets for help on using tickets.