<script> $(function () { //默认是发货追溯(供应商)页面 document.getElementById('ViewBackSupp').click(); //判断登录是否过期 setInterval(GetIsHaveOverTime, 5000); }); function GetIsHaveOverTime() { $.ajax({ type: "post", dataType: "json", url: '/Home/GetIsHaveOverTime', //回发到的页面 success: function (data) { //0 未过期 1 已过期 ,过期则返回登录界面 if (data.result == 1) { window.location.href = '/Login/Index'; } } }) } </script>
转载于:https://www.cnblogs.com/lhlong/p/7642328.html
相关资源:html定时抓取程序