watch function instead of load in jquery code example Example: jquery ready // jQuery document ready function $(function() { // do stuff });