summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/html/rendering/non-replaced-elements/the-page/iframe-scrolling-attribute.html
blob: d04e2dd56f993a8bde5e4d6e6a285226abd74555 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
<!DOCTYPE html>
<title>iframe: changing the scrolling attribute</title>
<link rel="author" href="mailto:masonf@chromium.org">
<link rel="help" href="https://html.spec.whatwg.org/multipage/rendering.html#the-page">
<link rel="match" href="iframe-scrolling-attribute-ref.html">

<style>
    iframe {
        width: 100px;
        height: 100px;
    }
</style>

<p>These two iframes should *both* render with scrollbars:</p>
<iframe src="support/big-page.html" scrolling="unknown"></iframe>
<iframe src="support/big-page.html" scrolling="unknown"></iframe>

<script>
  var iframe = document.getElementsByTagName("iframe")[1];
  // Setting scrolling=no and then back to scrolling=unknown
  // should result in a final value of auto.
  iframe.setAttribute("scrolling", "no");
  iframe.setAttribute("scrolling", "unknown");
</script>