Skip to main content

Bug Tracker

Side navigation

#9947 closed bug (worksforme)

Opened August 01, 2011 07:15AM UTC

Closed August 01, 2011 12:46PM UTC

about jQuery(html, props)

Reported by: nlx0201@163.com Owned by:
Priority: undecided Milestone: None
Component: unfiled Version: 1.4.2
Keywords: Cc:
Blocked by: Blocking:
Description

I find a bug of Jquery(html,props).

example:

$("<div>", {

"class": "test",

text: "Click me!",

click: function(){

$(this).toggleClass("test");

}

}).appendTo("body");

"click" is wrong.I think this "onclick".

Attachments (0)
Change History (1)

Changed August 01, 2011 12:46PM UTC by dmethvin comment:1

resolution: → worksforme
status: newclosed

The example seems to work. If you are suggesting that we change "click" to "onclick" we can't do that without breaking existing user code.

http://jsfiddle.net/dmethvin/QFxCx/