summaryrefslogtreecommitdiffstats
path: root/testing/marionette/harness/marionette_harness/www/deletingFrame.html
blob: d891605aff039c24ce060a3ac56cee83f6c03c89 (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
25
26
27
28
29
<html>
<head>
    <title></title>
</head>
        <script type="text/javascript">
            function remove() {
                var iframe = document.getElementById("iframe1");
                var myDiv = document.getElementById("myDiv");
                myDiv.removeChild(iframe);
            }
            function addBack() {
                var iframe = '<iframe src="javascriptPage.html" marginheight="0" marginwidth="0" topmargin="0" leftmargin="600" allowtransparency="true" frameborder="0" height="600" scrolling="no" width="120" id="iframe1"></iframe>';
                var myDiv2 = document.getElementById("myDiv2");
                myDiv2.innerHTML = iframe;
            }
        </script>
<body>

<div id='myDiv'>
<iframe src="formPage.html" marginheight="0" marginwidth="0" topmargin="0" leftmargin="0" allowtransparency="true"
        frameborder="1" height="900" scrolling="no" width="500" id="iframe1"></iframe>
        
        </div>
<div id='myDiv2'>

</div>
<input type='button' id='addBackFrame' value='Add back frame' onclick='addBack();' />
</body>
</html>