title: How to prevent page reload after alert box on key down event?
body: <p>I want to prevent page reload after clicking ok on alert box. click search button is ok. But now I meet problem in enter  key down event. Someone help me please.</p>
  
  <p>This is my html</p>
  
  <pre><code>&lt;div id="email"&gt;
   &lt;input type="text" id="txtSearchEmail" name="email" onkeydown="Javascript: if (event.keyCode==13) {JS_Search(); event.preventDefault();}" style="width: 161px; height: 16px; padding: 2px; border: 1px solid #a8a8a8; font-size: 13px; color: #434343" /&gt;
  &lt;/div&gt;
  &lt;div id="search"&gt;
  &lt;a class="gai-button" style="width: 96px; height: 25px;" onclick="JS_Search();"&gt;&lt;img  src="images/findamessage_search.jpg" alt="" /&gt;&lt;/a&gt;
  &lt;/div&gt;
  </code></pre>
  
  <p>This is my javascript </p>
  
  <pre><code>if() {
  //some coding
  }
  else {
  alert ("Not found!");
  return false;
  }
  </code></pre>