Skip to main content

Bug Tracker

Side navigation

#836 closed bug (invalid)

Opened January 17, 2007 01:01PM UTC

Closed January 17, 2007 01:46PM UTC

Last modified June 19, 2007 08:49AM UTC

load

Reported by: Vladik Owned by:
Priority: minor Milestone: 1.1
Component: core Version: 1.1
Keywords: load Cc:
Blocked by: Blocking:
Description

Make

<p>what</p>

And code in (document.ready(...)):

$("p").load (function () {alert("Hello!");});

But, when I look in my inspector (FireFox): I don't see: <p onload="alert(Hello!)">what</p> ;-(

hothing change ;-(

Attachments (0)
Change History (2)

Changed January 17, 2007 01:15PM UTC by Vladik comment:1

Also in jquery 1.0.4 I don't see anyone warning in bugfire...

But in 1.1 I see: 3!

test for equality (==) mistyped as assignment (=)?

jquery.js (line 1)

eateElement("tbody"));jQuery.each(a,function(){fn.apply(obj,[clone?this.cloneNode(true):this])})})}};jQuery.extend=jQuery.fn.extend=function(){var target=arguments[0],a=1;if(arguments.length==1){target=this;a=0}var prop;while(prop=arguments[a++])for(var i

anonymous function does not always return a value

jquery.js (line 1)

Name)});if(m[1]=="#"&&ret.length==1){var tmp=r;r=[];jQuery.each(tmp,function(){if(this.getAttribute("id")==m[2]){r=[this];return false}})}ret=r}t=t.replace(re2,"")}}if(t){var val=jQuery.filter(t,r);ret=r=val.r;t=jQuery.trim(val.t)}}if(ret&&ret[0]==context

anonymous function does not always return a value

jquery.js (line 1)

_resort(m);return false}});if(m[1]==":"&&m[2]=="not")r=jQuery.filter(m[3],r,true).r;else if(m[1]=="."){var re=new RegExp("(^|\\s)"+m[2]+"(\\s|$)");r=jQuery.grep(r,function(e){return re.test(e.className||"")},not)}else{var f=jQuery.expr[m[1]];if(typeof f!=

anonymous function does not always return a value

jquery.js (line 1)

cur==elem||result=="odd"&&num%2==1&&cur==elem)return cur}},sibling:function(n,elem){var r=[];for(;n;n=n.nextSibling){if(n.nodeType==1&&(!elem||n!=elem))r.push(n)}return r}});jQuery.event={add:function(element,type,handler,data){if(jQuery.browser.msie&&ele

Changed January 17, 2007 01:46PM UTC by joern comment:2

resolution: → invalid
status: newclosed

The examples for the various bind() shortcuts are somewhat misleading. While the event is attached to the element, there is no explicit HTML written, therefore you never get the output of <p onload="alert(Hello!)">what</p>.

The mentioned warnings are misleading, too: Firefox warns about code that eventually could pose a problem, but currently it simply doesn't.