Skip to main content

Bug Tracker

Side navigation

#4249 closed bug (invalid)

Opened February 25, 2009 04:32PM UTC

Closed February 25, 2009 11:48PM UTC

Last modified February 13, 2011 10:45PM UTC

Odd string to number conversion

Reported by: chrisbarr Owned by:
Priority: low Milestone: 1.4
Component: css Version: 1.3.2
Keywords: Cc:
Blocked by: Blocking:
Description

If I have a z-index of 100 on an item and I run the following code:

$("#myThing").css("z-index",$("#myThing").css("z-index")+100);

the new z-index is 100100 not 200 as I would have expected.

Attachments (0)
Change History (3)

Changed February 25, 2009 04:51PM UTC by chrisbarr comment:1

Several people have told me this is the expected behavor and not a bug. $(x).css() always returns a string. I need to use parseInt() to convert it to an integer.

Please close this ticket - sorry for the trouble.

Changed February 25, 2009 11:48PM UTC by dmethvin comment:2

resolution: → invalid
status: newclosed

Changed February 13, 2011 10:45PM UTC by jitter comment:3

component: unfiledcss
priority: minorlow