You can put all your functions inside one  $(document).ready( ); , or 
use the shorthand $(function(){}); , but then you have to be aware that 
ajax generated html will not fire because the page hasn't reloaded.
For ajax generated code you best put your functions outside the 
$(document).ready( ); and call then inside.


Caton, Paul schreef:
> Please forgive what might seem a stupidly basic question but I'm new to
> jQuery and the tutorials/API doc have not made the answer clear to me:
>
> Should you use a separate 
>
>     $(document).ready(function(){
>         // Your code here
>       });
>
> for each function you write, or do you just have one wrapping "ready
> statement" and put all your functions inside it?
>
> Thanks,
>
> Paul Caton.
>
> _______________________________________________
> jQuery mailing list
> [email protected]
> http://jquery.com/discuss/
>
>
>   


-- 
David Duymelinck
________________
[EMAIL PROTECTED]


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

Reply via email to