If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Data Access, Manipulation & Batch Languages > ASP > Reload page using asp

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 04-25-04, 22:20
michaelfg81 michaelfg81 is offline
Registered User
 
Join Date: Mar 2004
Posts: 202
Reload page using asp

Hi here,

I got this two web page which are interlink login and logout.
When i login, i set a session to hold the name of the user. The name of the user will be display on top of the web page login.asp. After that, when i log out with the coding like this

<html>
<body>
<%
session.contents.remove("username")
response.Redirect("index.asp")

%>

</body>
</html>

i cant seem to delete the name on the session which is display on the login page. I will be deleted when i click on the refresh.
How come could this happen if i already change the session name to "" but when i go to the page login, the name is still there?
Can anyone help me
Thanks
Reply With Quote
  #2 (permalink)  
Old 04-25-04, 23:57
MrWizard MrWizard is offline
Registered User
 
Join Date: Mar 2003
Location: Atlanta, GA
Posts: 191
Why not just use Session.Abandon?
__________________
Tim
Reply With Quote
  #3 (permalink)  
Old 04-26-04, 01:18
michaelfg81 michaelfg81 is offline
Registered User
 
Join Date: Mar 2004
Posts: 202
Hi sir,

I did use session.abandon and session.contents.removeall() ...........both works but i still have to press F5 (refresh) to refresh the page so that the session at the login page will dissapear or not it will still appear with the suer name before that.
Please help.
Thanx
Reply With Quote
  #4 (permalink)  
Old 04-26-04, 02:28
Bullschmidt Bullschmidt is offline
Guru
 
Join Date: Jun 2003
Location: USA
Posts: 1,032
Perhaps try putting something like this toward the top of your database-oriented Web pages:

<%
Response.Expires = -1000 ' Make browser not cache pg.
%>
__________________
J. Paul Schmidt, Freelance Web and Database Developer
www.Bullschmidt.com
Access Database Sample, Web Database Sample, ASP Design Tips
Reply With Quote
  #5 (permalink)  
Old 04-26-04, 05:05
michaelfg81 michaelfg81 is offline
Registered User
 
Join Date: Mar 2004
Posts: 202
Thank you sir.I manage to do it already.
Thanx again
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On