ladybird/Tests/LibWeb/Text/input/DOM/getElementById-empty-string.html
Tim Ledbetter f666d967d6 LibWeb: Ensure document.getElementById("") returns null
Previously, if a document had an element whose id was the empty string,
then `document.getElementById("")` and `element.getElementById("")`
would return that element.
2024-07-23 08:58:22 +02:00

8 lines
196 B
HTML

<!DOCTYPE html>
<script src="../include.js"></script>
<div id=""></div>
<script>
test(() => {
println(`document.getElementById(""): ${document.getElementById("")}`);
});
</script>