Re: Problem with URL
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.javascript archive

Re: Problem with URL

From: Randy Webb <HikksNotAtHome@aol.com>
Date: Wed Nov 30 2005 - 13:36:29 CET

VK said the following on 11/30/2005 6:07 AM:
> TONI-BCN wrote:
>
>>I have a HTML page, for example http://www.mypage.html.
>>
>>If I want to go to www.google.com, is some way to be able to recover
>>with Javascript "www.google.com"?
>>
>>I have tried it with window.location, etc but she does not serve to me
>>since it shows "http:www.mypage.html to me".
>
>
> If I uderstand you properly, you want to navigate from
> http://www.myserver.com/mypage.html to http://www.google.com using
> JavaScript ?
>
> Then you may do it in this way:
>
> window.location.href = "http://www.google.com";
>

He wants to know where you are attempting to go before you leave the page.

You are on Page1.html and type in www.google.com in the address bar, he
wants to know that before you leave the page.

The answer is No unless they are leaving via a link on your page.
Otherwise, you have no reliable secure way of knowing where they are
going, only that they are going.

-- 
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/
Received on Sat Dec 3 04:33:24 2005