<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> | |
<html> | |
<head> | |
<title>Test for HTMLSelectElement.remove() on an Options object</title> | |
<SCRIPT LANGUAGE=javascript> | |
function test() { | |
var zipselect = document.getElementById("theSelect"); | |
var before = zipselect.options.length; | |
zipselect.remove(zipselect.options[0]); | |
var after = zipselect.options.length; | |
if (before > after) | |
document.getElementById("theDiv").innerHTML = "test passed" | |
if (window.testRunner) | |
testRunner.dumpAsText(); | |
} | |
</SCRIPT> | |
</head> | |
<body onload="test();"> | |
<div id="theDiv">test failed</div> | |
<form> | |
<select id="theSelect"> | |
<option value="ALL" selected >hello</option> | |
</select> | |
</form> | |
</body> | |
</html> |