Thursday, 26 July 2012

Self invoking Function in JS


//self invoking function expression
   (function sayHello() {
      alert("hello!");
   })();

This function will automatically triggered on page load


No comments:

Post a Comment