Frameset onload Event

定義和用法
onload 事件在頁面載入完成后被觸發(fā)。
語法
onload="JavaScriptCode"
參數(shù) | 描述 |
---|---|
JavaScriptCode | 必須。在事件觸發(fā)后執(zhí)行的Javascript代碼。 |
瀏覽器支持
所有主要瀏覽器都支持 onload 事件
實(shí)例
實(shí)例
框架集載入完成后彈出 "Page is loaded":
<html>
<head>
<script>
function load()
{
alert("Page is loaded");
}
</script>
</head>
<frameset onload="load()" cols="50%,50%">
? <frame src="frame_a.htm">
? <frame src="frame_b.htm">
</frameset>
</html>
<head>
<script>
function load()
{
alert("Page is loaded");
}
</script>
</head>
<frameset onload="load()" cols="50%,50%">
? <frame src="frame_a.htm">
? <frame src="frame_b.htm">
</frameset>
</html>
嘗試一下 ?

更多建議: