只需在来源页的头部加入
<script type="text/javascript"> if (top.location.href != self.location.href) top.location.href = self.location.href;</script>
就可以阻止用iframe加载了
.....
<script type="text/javascript"> if (top.location.href != self.location.href) top.location.href = self.location.href;</script>
就可以阻止用iframe加载了
转载请注明:谷谷点程序 » js阻止用iframe框架加载本页面