Steps to reproduce: just click the above button
Expected results: you should see a select (drop-down list) with 4 options (4 ordered choices) available.
Actual results in Internet Explorer 7 and Internet Explorer 8: a Web Error critical message modal window will pop up stating "Line: 70 Error: Invalid argument."
DOM 1 HTML, Interface HTMLSelectElement on the add method and
DOM 2 HTML, Interface HTMLSelectElement on the add method say:
void add(in HTMLElement element, in HTMLElement before)
"Add a new element to the collection of OPTION elements for this SELECT. This method is the equivalent of the appendChild method of the Node interface if the before parameter is null. It is equivalent to the insertBefore method on the parent of before in all other cases. (...)
before of type HTMLElement:
The element to insert before, or null for the tail of the list."
Firefox 1.5, Firefox 2, Firefox 3, Opera 9.27, Opera 9.50, Safari 3.1, Konqueror 3.5.8, Seamonkey 1.x Seamonkey 2.x, NS 7.0, NS 7.2, K-meleon 1.x, Galeon 2.0.4, Epiphany 2.22 all pass this test.
This bug has been reported at connect's IE beta feedback as bug 388710. This bug has been closed by the IE team and will not be fixed for the release of IE 8 final.