There are errors on your page. And <object> and <frame> are not suitable for what you want. Why not just use the iframe, which validates in HTML5! This works and validates:
Code:
<!DOCTYPE html>
<html>
<head>
<script type="text/javascript">
function RedirFrames(which_div1, url1, which_div2, url2, which_div3, url3, which_div4, url4)
{
document.getElementById(which_div1).src = url1;
document.getElementById(which_div2).src = url2;
document.getElementById(which_div3).src = url3;
document.getElementById(which_div4).src = url4;
}
</script>
<title></title>
</head>
<body><div>
<a href="javascript: void(0)" onclick="RedirFrames('iframe1', 'http://www.dynamicdrive.com', 'iframe2', 'http://www.webkit.com', 'iframe3', 'http://www.cryer.co.uk/resources/javascript/script8.htm', 'iframe4', 'http://www.cryer.co.uk/resources/javascript/script8.htm#SimpleForms')" >Load iframes</a>
<a href="javascript: void(0)" onclick="RedirFrames('iframe1', '', 'iframe2', '', 'iframe3', '', 'iframe4', '')" >Unload iframes</a>
<div style="position: absolute; left: 30px; top: 30px; right: 51%; bottom: 51%; "><iframe id='iframe1' name="iframe1" style="position: absolute; width: 100%; height: 100%" ></iframe></div>
<div style="position: absolute; left: 50%; top: 30px; right: 30px; bottom: 51%"><iframe id='iframe2' name="iframe2" style="position: absolute; width: 100%; height: 100%"></iframe></div>
<div style="position: absolute; left: 30px; top: 51%; right: 51%; bottom: 30px"><iframe id='iframe3' name="iframe3" style="position: absolute; width: 100%; height: 100%" ></iframe></div>
<div style="position: absolute; left: 50%; top: 51%; bottom: 30px; right: 30px"><iframe id='iframe4' name="iframe4" style="position: absolute; width: 100%; height: 100%"></iframe></div>
</div></body>
</html>
Arie Molendijk.
Bookmarks