aspose file tools*
The moose likes Servlets and the fly likes refresh check Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of JavaScript Promises Essentials this week in the JavaScript forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "refresh check" Watch "refresh check" New topic
Author

refresh check

kevin schmidt
Ranch Hand

Joined: Aug 24, 2001
Posts: 85
Hi,
I've written a JSP page, but need to know if someone was refreshed or reloaded a page. How can I check to see of someone has reloaded/refreshed their webpage? TIA.
Kevin
PC RE
Greenhorn

Joined: Aug 28, 2001
Posts: 29
where do u want to check this? on the server side or the client side?
-PC RE
kevin schmidt
Ranch Hand

Joined: Aug 24, 2001
Posts: 85
server side
Brian Blesbok
Greenhorn

Joined: Sep 03, 2001
Posts: 9
if the person has refreshed the data, then this will have come from the server, and then the server will be able to know about it... ie: the servlet will be run to do this?!?!?!
Thiru Thangavelu
Ranch Hand

Joined: Aug 29, 2001
Posts: 219
How abt the client side?


Thanks,<br />Thiru<br />[SCJP,SCWCD,SCBCD]
PC RE
Greenhorn

Joined: Aug 28, 2001
Posts: 29
Kevin,
Because of the nature of the browser/HTTP it maynot be possible to send a message back to the server when the user clicks either stop or refresh. Instead the browser closes the socket connection to the server and the server will throw an IOException in such a case and u could detect this....
Not really sure of any other way other than the above.
Let me know how u solved the problem....
Thanks,-PC RE
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: refresh check