iframe或者frameset 中的頁面在跳轉後顯示在最外層,例如登陸校驗時跳轉到登陸頁面,應該在最外層顯示,而不是加載在iframe中顯示。
<script language="javascript">
window.onload=function(){
if(self!=top){
top.location.href="login";
}
}
</script>
iframe或者frameset 中的頁面在跳轉後顯示在最外層,例如登陸校驗時跳轉到登陸頁面,應該在最外層顯示,而不是加載在iframe中顯示。
<script language="javascript">
window.onload=function(){
if(self!=top){
top.location.href="login";
}
}
</script>