title: jQuery/JavaScript - Start one function once another has finished?
body: <p>What is the best way to fire a function once another has finished? </p>
  
  <p>At the moment I have 6 functions that I'm calling on DOM load like this:</p>
  
  <pre><code>$(document).ready(function(){
      func1();
      func2();
      func3();
      func4();
      func5();
      func6();
  });
  
  function func1(){
      do some stuff
  }
  
  function func2(){
      do some stuff
  }
  
  function func3(){
      do some stuff
  }
  
  function func4(){
      do some stuff
  }
  
  function func5(){
      do some stuff
  }
  
  function func6(){
      do some stuff
  }
  </code></pre>
  
  <p>But I want them to fire one after another. How would I do this?</p>
  
  <p>Thanks in advance</p>