22 lines
974 B
HTML
22 lines
974 B
HTML
<!DOCTYPE html>
|
|
<html>
|
|
<body>
|
|
<p>This test checks that the selected property of an option is initialized correctly even prior to the </select> being parsed. https://bugs.webkit.org/show_bug.cgi?id=32641</p>
|
|
<p>Before querying selectedIndex, [theOption].selected = <span id="logOne"></span></p>
|
|
<p>[theSelect].selectedIndex = <span id="logTwo"></span></p>
|
|
<p>After querying selectedIndex, [theOption].selected = <span id="logThree"></span></p>
|
|
<select id="theSelect" style="display:none">
|
|
<option id="theOption">lalala</option>
|
|
<script>
|
|
if (window.testRunner)
|
|
testRunner.dumpAsText();
|
|
var o = document.getElementById('theOption');
|
|
document.getElementById('logOne').textContent = o.selected;
|
|
document.getElementById('logTwo').textContent = document.getElementById('theSelect').selectedIndex;
|
|
document.getElementById('logThree').textContent = o.selected;
|
|
</script>
|
|
</select>
|
|
</body>
|
|
</html>
|
|
|