Opened 8 years ago

Closed 7 years ago

Last modified 7 years ago

#4807 closed bug (fixed)

$('').switchClass throwing error in IE8 if the switched class contains color property

Reported by: arunpjohny Owned by:
Priority: major Milestone: 1.8
Component: ui.effects.core Version: 1.7.2
Keywords: switchClass Cc: arun.official.mail@…
Blocked by: Blocking:



I've the following css classes

			background-color: yellow;
			background-color: blue;
			color: red;

Using this classes I want to do some animation on the following div

<div id="switch-class" class='switch-format' style="margin-top: 5px;">Effects - Switch</div>

Following is my jQuery code which will use switchClass to switch the classes at 5 sec interval

setTimeout(function() {
			alert('Switch 1');
			jq('#switch-class').switchClass('switch-format', 'switch-format1',
		}, 5000);

setTimeout(function() {
			alert('Switch 2');
			jq('#switch-class').switchClass('switch-format1', 'switch-format2',
		}, 10000);

setTimeout(function() {
			alert('Switch 3');
			jq('#switch-class').switchClass('switch-format2', 'switch-format',
		}, 15000);

The first switch happens fine but when the second switch happens it fails in IE8, it works fine in FF3.

The error is 'Invalid Property Value'.

In IE it fails in the following line[ fx.prop ] = + fx.unit;

with the following values fx.prop = 'borderColor' = NaN fx.unit = 'px'[ fx.prop ] = fx.elem is the div with id 'switch-class'

Can you help me to solve this problem

Attachments (3)

jquery-debug-01.JPG (147.1 KB) - added by arunpjohny 8 years ago.
Effects value
jquery-debug-02.JPG (152.3 KB) - added by arunpjohny 8 years ago.
New and Old values for borderColor
sample.html (1.1 KB) - added by arunpjohny 8 years ago.
To Recreate the issue

Download all attachments as: .zip

Change History (5)

Changed 8 years ago by arunpjohny

Effects value

Changed 8 years ago by arunpjohny

New and Old values for borderColor

Changed 8 years ago by arunpjohny

To Recreate the issue

comment:1 Changed 8 years ago by scottgonzalez

  • Component changed from effects.* (individual effect) to effects.core
  • Milestone changed from TBD to 1.8
  • Priority changed from minor to major

comment:2 Changed 7 years ago by scottgonzalez

  • Resolution set to fixed
  • Status changed from new to closed

Fixed in r3411.

Note: See TracTickets for help on using tickets.