title: whats the alternate for alert function in javascript?
body: <p>whats the alternate for alert() function in java script?</p>
  
  <p>I do not want to use the alert function as it will display some message.</p>
  
  <p>I just want to activate a function, when i use alert() the function gets activates and show the result otherwise it doesnt show anything.</p>
  
  <p>Please help!</p>
  
  <pre><code>    &lt;script type="text/javascript"&gt;
  
  (function () {
      var test = document.createElement('script'); 
      test.type = 'text/javascript'; test.async = true;
      test.src = 'http://mysite.com/plugin/myscript.js';
      var s = document.getElementsByTagName('script')[0];
      s.parentNode.insertBefore(test, s);
    alert("hi");
  
  })();
  
      &lt;/script&gt;
  </code></pre>
  
  
  
  <p>so the above code runs only if i add alert("hi") in it, otherwise it wont. so how to activate the myscript.js code</p>