tags:

views:

273

answers:

2

In using this cool onload function from JQuery

$(document).ready(function(){ // my stuff }

do I need to worry about overwriting anything else that may have called it?

+6  A: 

In jQuery, that function adds to the ready queue I believe, so you can write multiple ready() functions without worrying about overwriting previous ones (they just stack).

OneNerd
perfect, thanks!
Yar
+1  A: 

$(document).ready is an event, so as many subscribers as you want can wire up to it.

TreeUK
awesome, thank you.
Yar