清除浏览器历史记录代码
类别: ASP教程
Code to clear browser history
/* This logout.asp is used to clear the back pages of the browser,
/* if the user has logged out.
/* if there are no specific vbscripting to be done then you can
/* use this file as logout.htm
<%
/* Clear all your sessions over here and do other
/* desired things
%>
<SCRIPT LANGUAGE=javascript>
{
var Backlen=history.length;
history.go(-Backlen);
top.window.location.href ="../esadmin/administer.asp";
}
</SCRIPT>
/* here the "../esadmin/administer.asp" page is the
/* desired page to be displayed after the user logs out
To use the code above, click and drag your mouse over the code to highlight it. Then right click on the
highlighted code and click "Copy." Now you may paste it into your code editor.
/* This logout.asp is used to clear the back pages of the browser,
/* if the user has logged out.
/* if there are no specific vbscripting to be done then you can
/* use this file as logout.htm
<%
/* Clear all your sessions over here and do other
/* desired things
%>
<SCRIPT LANGUAGE=javascript>
{
var Backlen=history.length;
history.go(-Backlen);
top.window.location.href ="../esadmin/administer.asp";
}
</SCRIPT>
/* here the "../esadmin/administer.asp" page is the
/* desired page to be displayed after the user logs out
To use the code above, click and drag your mouse over the code to highlight it. Then right click on the
highlighted code and click "Copy." Now you may paste it into your code editor.
- 上一篇: 如何使用asp创建dsn?
- 下一篇: 怎样读取一个文本文件的内容?
-= 资 源 教 程 =-
文 章 搜 索