Jquery to append a div and to remove a div
<p>Here is my problem, </p>

<p>I have a select box where i need to validate if the val() becomes 0, then append a text insed a span with class error stating that 'Please select a value'. Else need to remove that div. These happens when i click the submit button. Here is my code, </p>

<pre><code>if ($('.combo option:selected[value==0]')) {
    var error_span = $("div.info-cont ul.map-list li span.right")
        .append("&lt;br&gt;Please select an appropriate value")
        .addClass('error');
} else {

}
</code></pre>

<p>Now the problem is, if a value is selected in the selectbox, my appended span should get removed. Any help. Thanks in advance...</p>
