Source code
Revision control
Copy as Markdown
Other Tools
Test Info:
- This WPT test may be referenced by the following Test IDs:
- /html/semantics/embedded-content/the-iframe-element/iframe-src-encoding.html - WPT Dashboard Interop Dashboard
<!DOCTYPE html>
<meta charset=windows-1252>
<title>iframe src URL is parsed using document encoding</title>
<script src="/resources/testharness.js"></script>
<script src="/resources/testharnessreport.js"></script>
<body>
<script>
async_test(t => {
let frame = document.createElement('iframe');
frame.src = "resources/frame-encoding.html?\u00DF";
document.body.appendChild(frame);
frame.onload = t.step_func(() => {
assert_equals(frame.contentWindow.location.search, "?%DF");
assert_equals(frame.contentWindow.test.textContent, "?%DF");
assert_equals(frame.src, new URL("resources/frame-encoding.html?%DF", location.href).href);
t.done();
});
});
</script>