用戶退出我用session="" 怎麼沒有清空session求高手解答
if trim(request( "action "))= "btdelete " then
set rs=server.CreateObject( "ADODB.Recordset ")
sqldel= "select * from updates where cname= ' "& session( "user_name ") & " ' "
rs.open sqldel,conn,1,3
rs.delete
rs.close
'session.Contents.Removeall( "user_name ")
response.write " <SCRIPT language=JavaScript> alert( '刪除用戶成功! \n \n你刪除的用戶名為: "&session( "user_name ")& " '); " '
session( "user_name ")= " "或session.Abandon()
response.write "window.document.location.href= 'index.htm '; </script> "
response.End()
------解决方案--------------------怎么会呢,session( "user_name ")= " "或session.Abandon()都是可以情况session的
你怎么判断没有清空呢?
在你要求权限的每个页面都要判断session的
------解决方案--------------------跳转以后session( "user_name ")= " "或session.Abandon()不执行
session( "user_name ")= " "或session.Abandon()应该在跳转以前