Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Rhinorhino on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

passing referring url to Pop Up Window

Status
Not open for further replies.

Guest_imported

New member
Joined
Jan 1, 1970
Messages
0
Hi,

I want to show the refering page in a pop up window like this:

<script language=&quot;JavaScript&quot;> <!--
document.write( document.referrer );
-->
</script>

Then refering url doesn't seem to pass when I use a link like from the parent.

<a href=&quot;javascript:openpopup()&quot;>Popup</a>

Any ideas? Thanks!


 
I think that your JS syntax is correct (though I don't see it - what you posted is just a part of something).

You should know the following about [tt]referrer[/tt]:
If the user clicked on a link to get to the current URL, referrer contains the URL the user linked from.
But, referrer is empty if you typed a URL in the address bar, or used some other means to get to the current URL. Also, referrer is empty if the server does not provide environment variable information.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top