How to Avoid redirection in this Javascript?
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/14292978/javascript-prompt-displaying-executed-value">Javascript Prompt displaying executed value</a>  </p>
</blockquote>



<p>I know i can insert prompt() in this code, but want to know how to stop this script to show result on another page. I'm trying to show the result on the same page through prompt.</p>

<pre><code>&lt;input type="button" value="Short URL" onClick="javascript:void(location.href='http://taimoorsultan.com/y/yourls-api.php?signature=05e2685fc7&amp;format=simple&amp;action=shorturl&amp;url='+escape(location.href));"&gt;
</code></pre>

<p>Thanks!</p>
