在登录页面添加如下代码 <script type="text/javascript"> /* session过期时,应用此方法显示一个界面 */ if(top.location!=this.location){ top.location=this.location; } </script>