jQuery - if select option is unselected, remove an element
<p>I'm working on a multiselect that creates an <code>&lt;li&gt;</code> using the text of each <code>:selected</code> option.  How would I go about removing that <code>&lt;li&gt;</code> if the option becomes unselected?</p>

<p>I'm using the code below (from here) to append the <code>&lt;li&gt;</code> for each <code>:selected</code> item.</p>

<pre><code>    $('option:selected', select).each(function(index, value) {
            $('ul.multiselect-dropdown-options-'+name+'').append('&lt;li&gt;'+$(value).text()+'&lt;/li&gt;');
        });
</code></pre>
