session.invalidate() when closing window

Hi,

I'm tryingto use the onunload function to end a session when a user closes a window but the session.invalidate() function seems to occur everytime the page refreshes.

<BODY onunload="<%session.invalidate()%">

It works if I display a message box instead of calling a session method.

Thanks for your help,

Nisha

[360 byte] By [nishzonea] at [2007-10-2 13:07:28]
# 1
I cannot use frames. Can anybody help?
nishzonea at 2007-7-13 10:32:35 > top of Java-index,Enterprise & Remote Computing,Web Tier APIs...