it also doesnt remove an anchor and then re-append it!
-----Original Message-----
From: Christopher Dawes [mailto:[EMAIL PROTECTED]
Sent: 01 October 2003 15:50
To: [EMAIL PROTECTED]
Subject: RE: [ cf-dev ] OT : Links
Here's something I whipped up for the athletes foot (with a little mod to
include your 'javascript' and '_blank' bits. It works on Moz Firebird/IE
5+/Opera 7 - pretty much any 5+ browser should do it... as long as they
support document.all
<SCRIPT>
function appointToken() {
var urltoken = "&cfid=#cfid#&cftoken=#cftoken#";
var anchorTags = document.all.tags("A");
for ( a=0; a < anchorTags.length; a++ ) {
if (
document.all.tags("A")[a].href.indexOf("mailto:") == -1
&&
document.all.tags("A")[a].href.indexOf("javascript:") == -1
&& document.all.tags("A")[a].target !=
"_blank" )
{
document.all.tags("A")[a].href =
document.all.tags("A")[a].href + urltoken;
}
}
}
appointToken();
</SCRIPT>
Kind Regards,
Christopher Dawes
Dawes International
-----Original Message-----
From: Robertson-Ravo, Neil (RX)
[mailto:[EMAIL PROTECTED]
Sent: Thursday, 2 October 2003 12:06 AM
To: '[EMAIL PROTECTED]'
Subject: RE: [ cf-dev ] OT : Links
:-)
-----Original Message-----
From: Rich Wild [mailto:[EMAIL PROTECTED]
Sent: 01 October 2003 15:08
To: '[EMAIL PROTECTED]'
Subject: RE: [ cf-dev ] OT : Links
lol. that JS looks familiar to me!
> -----Original Message-----
> From: Robertson-Ravo, Neil (RX)
> [mailto:[EMAIL PROTECTED]
> Sent: 01 October 2003 14:59
> To: '[EMAIL PROTECTED]'
> Subject: [ cf-dev ] OT : Links
>
>
> I have a block of JS which appends CFID/CFTOKEN to any link
> in a page, however, if one of those links as an anchor in it,
> it simply ignores the link and doesnt append the cfid/cftoken....
>
> What I need it to is, append the cfif/cftoken AND the anchor
> reference, but with the anchor reference at the end of the string!
>
> anyone?
>
>
> <script language="Javascript">
>
> function setLinks() {
> var thisLink = "";
> var urltoken =
> "&cfid=#cfid#&cftoken=#cftoken#";
>
> for (var i=0; i<document.links.length; i++) {
> thisLink = document.links[i];
> //if
> ((thisLink.href.indexOf('mailto:') ==
> -1) && (thisLink.href.indexOf('javascript:') == -1) &&
> (thisLink.target.toLowerCase() != '_blank')) {
> if
> ((thisLink.href.toLowerCase().indexOf('appname') > -1) &&
> (thisLink.href.toLowerCase().indexOf('javascript:') == -1) &&
> (thisLink.href.toLowerCase().indexOf('##') == -1)) {
> //if
> (thisLink.href.indexOf('homepage.cfm') != -1) {
> thisLink.href += urltoken;
> //}
> }
> }
>
> }
> </script>
>
> --
> ** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
>
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail:
> [EMAIL PROTECTED] For human help, e-mail:
> [EMAIL PROTECTED]
>
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]
--
** Archive: http://www.mail-archive.com/dev%40lists.cfdeveloper.co.uk/
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]