Browser Neutral Way to add options to a select element in javascript
<p>I just learned something interesting. The add method for the javascript select object in IE 6 takes only one parameter. It throws an error when you pass it two parameters which I believe is the <a href="http://www.w3.org/TR/1998/REC-DOM-Level-1-19981001/level-one-html.html">standard</a>, even as <a href="http://msdn.microsoft.com/en-us/library/aa768859(VS.85).aspx">documented</a> on the MSDN site.</p>

<p>My question is this. What is your best-practice recommendation for programmatically adding option elements to a select element in javascript?</p>

<ul>
<li>Call the add method differently based on the value of the user agent?</li>
<li>Wrap the select object in a class that provides the proper method signature?</li>
<li>Use a javascript library which does this for you (specify which library)?</li>
</ul>
