In my application i am using
$(document).ready()
What is the difference between this and
$(document).onload()
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
The
readyis triggered when only the DOM becomes ready whileonloadtriggers when all resources of the page including DOM, images, frames, etc have loaded.See:
$(document).ready vs. $(window).load
Note that
readylies with jQuery not raw javascript so I assume you know that and that way comparison seems logical.