• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Getting the URL in the address bar

 
Ranch Hand
Posts: 415
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

If a user is working in my webapplication and all of a sudden if he visits some other site in the same browser by typing the url(which is not part of my application) in the address bar ........

i want to get to know when the user does that ......because when the user goes out of my appl , i want my server to be notified immediately

how can i achieve that ?? may be i can do something on onUnload , but how to get to know the new url the user has typed

can any one let me know how to go about this ??
 
author
Posts: 15385
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There is no way to catch this user's action.

The onunload event fires for the back button, closing the browser, typing the url, refreshing the page, and normal page navigation. You really just need to deal with the users session tming out on the server.

Eric
 
sreenath reddy
Ranch Hand
Posts: 415
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks eric ...its sad that i cant catch that event .because i cant rely till the session time out becasue that user blocks the other users for resources

Anyways thanks do let me know if u have some idea ....okay even if its specific to IE because IE is the only browser my application supports
 
The human mind is a dangerous plaything. This tiny ad is pretty safe:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic