jquery : insert new DOM element disappears
<p>I'm new to this forum and looking forward to participating. </p>

<p>I am practicing with jQuery and trying to write a little interaction where
a user submits a word (a tag) and then it displays as a new DOM element within . However, the newTag flashes and then disappears immediately. </p>

<p>What am I missing>? </p>

<pre><code>$("form").submit(function() {
</code></pre>

<p>var $newTag = $("input:first").val();
      if ($newTag.length &lt; 20) {
                // adds an a success alert in an empty span
  $("span").text("Added. Add more?").show();
  $(""+$newTag+"").insertAfter("#currentTags");
        return true;
      }
      $("span").text("Less than 20 characters please.").show().fadeOut(2500);
      return false;
    });</p>
