load jquery after the page is fully loaded


I'm looking for a way to load jquery after the page is fully loaded.
well there are lots of questions and answers about it in here, but all describe how to run a script that needs jquery after either page or jquery fully loaded.
What I'm looking for is to load the page and then call jquery and after the jquery is loaded call the functions. something like:

   var fileref=document.createElement('script');
  fileref.setAttribute("src", 'http://code.jquery.com/jquery-1.7.2.min.js');
//Here I need an event to know that jquery is 
//loaded to run stuff that needs jquery

This question is tagged with javascript jquery html

~ Asked on 2013-09-26 10:58:17

The Best Answer is


Try this:

 $(document).ready(function() {
// When the document is ready
// Do something  

~ Answered on 2013-09-26 11:44:15


You can also use:

$(window).bind("load", function() { 
    // Your code here.

~ Answered on 2015-04-21 07:20:15

Most Viewed Questions: