Convert select dropdown into list for printing
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/7336437/how-to-convert-select-dropdown-into-an-unordered-list-using-jquery">How to convert &lt;select&gt; dropdown into an unordered list using jquery?</a>  </p>
</blockquote>



<p>I want to convert all select dropdowns into ul lists for printing. </p>

<pre><code>&lt;select&gt;
 &lt;option&gt;Item 1&lt;/option&gt;
 &lt;option&gt;Item 2&lt;/option&gt;
 &lt;option&gt;Item 3&lt;/option&gt;
&lt;/select&gt;
</code></pre>

<p>into:</p>

<pre><code>&lt;ul&gt;
 &lt;li&gt;Item 1&lt;/li&gt;
 &lt;li&gt;Item 2&lt;/li&gt;
 &lt;li&gt;Item 3&lt;/li&gt;
&lt;/ul&gt;
</code></pre>

<p>Why does this only show?: </p>

<pre><code>&lt;ul&gt;&lt;/ul&gt;
</code></pre>

<p>jquery:</p>

<pre><code>$('select').parent().append('&lt;ul&gt;&lt;/ul&gt;');
$('select option').each(function(){
  $('&lt;ul&gt;').append('&lt;li&gt;'+$(this).text()+'&lt;/li&gt;');
});

$('select').remove();
</code></pre>

<p>edit: removed select ID. I want to step through each  and not just one particular select.</p>
