Carlos Aguayo schrieb:
> Hi everyone,
> If I attach a function to Object.prototype outside the
> $(document).ready function, it gets executed when I load the page, is
> this a bug?
>   
I guess this is not a bug, it is by design. It is quite likely that 
jQuery iterates over all properties (functions) assigned to the 
document.ready event, therefore your function is executed, too.
You should generally avoid extending Object itself.

-- Jörn

_______________________________________________
jQuery mailing list
[email protected]
http://jquery.com/discuss/

Reply via email to