Easiest way to create a confirmation message with jQuery/JavaScript?
<p>How can I achieve this?</p>

<ol>
<li>A user clicks the delete link (with a class of "confirm").</li>
<li>Confirmation message appears asking "Are you sure?" with "Yes" and "Cancel" options.</li>
</ol>

<p>If yes is selected, the link continues as clicked, but if cancel is selected, the action is canceled.</p>

<p><strong>Update:</strong> Final working code with <code>confirm()</code> thanks to <a href="http://stackoverflow.com/questions/1844351/how-to-disable-click-with-jquery-javascript/1844412#1844412">this guy</a>:</p>

<pre><code>$('.confirm').click(function() {
    return confirm("Are you sure you want to delete this?");
});
</code></pre>
