$(document).ready(function() { ... });jQuery( callback )
Binds a function to be executed when the DOM has finished loading.
Just like $(document).ready()
$(function(){ // Document is ready });
Example: Uses both the shortcut for $(document).ready() and the argument to write failsafe jQuery code using the $ alias, without relying on the global alias.
jQuery(function($) { // Your code using failsafe $ alias here... });
document.getElementById$("#myDiv").css("border","3px solid red")
document.getElementById('myDiv')
|