Extra caution is recommended when installing recently uploaded/updated scripts (read more)
Be sure you trust any scripts you install

Direct Linker

Finds redirect links and replaces them with the final destination link

Finds redirect links and replaces them with the final destination link. Updated 2005.10.12





1 point
login to vote
topio 2 user
Posted Oct 3, 2006

Would be useful if the author mentioned some sites this script could be used on...

1 point
login to vote
Henrik N admin
Posted Dec 24, 2005

Rod: I believe your problem might be solved if the URL is unescaped _after_ isolating the final destination instead of before. That is, replace the last line with this (untested):

links.snapshotItem(i).href = unescape(links.snapshotItem(i).href.replace(/^.*\?.*(http(:\/\/|%3A%2F%2F)[^&]+).*$/i, "$1"));

1 point
login to vote
Rod McGuire scriptwright
Posted Dec 24, 2005

You could comment on this script if you were logged in.