Javascript issue confim message
<p>I made a short Javascript function:</p>

<pre><code>function confirmMessage() {
  var messages = confirm("Are you sure");
  if(messages) {
    //go trough
  }else{
    //stop, cancel the action
    return false;
  }
}
</code></pre>

<p>HTML:</p>

<pre><code>&lt;a href='?pagina=uitloggen'  onclick="confirmMessage()"&gt;
</code></pre>

<p>When I click cancel, it returns false and jumps to the else statement. But it doesn't stop the action! What is the problem here?</p>

<p>Thanks in advance.</p>
