sh**********@gmail.com wrote in news:eba47e8a-cac8-4215-9728-
6b**********@r15g2000prd.googlegroups.com:
Hi,
I am developing web application.using struts .I want the
javascript code for getting the previous URL of the browser.
any body help me.
Do you want "document.referrer"? That is the link that referred to the
current document, i.e. where we came from.
If the urls are being typed in directly (i.e. the user is not following
links), then there is no way to know. You can direct the browser back to
previous URLs using "window.history", but you cannot know what they are.