Hi there,
I’m trying to create content managed email links.
I’ve got a matrix containing Staff name, job title, thumbnail, bio and an email link.
I’ve used the following code in my template:
{encode="{email}" title="> click here to email {name}"}But when I view the site, it’s giving me the following:
<span>.(JavaScript must be enabled to view this email address)</span>[removed]/*<![CDATA[*/var l=new Array();var output = ;l[0]=>;l[1]=a;l[2]=/;l[3]=<;l[4]= 109;l[5]= 111;l[6]= 99;l[7]= 46;l[8]= 101;l[9]= 116;l[10]= 97;l[11]= 101;l[12]= 114;l[13]= 99;l[14]= 45;l[15]= 98;l[16]= 114;l[17]= 64;l[18]= 100;l[19]= 114;l[20]= 97;l[21]= 104;l[22]= 99;l[23]= 105;l[24]= 114;l[25]=>;l[26]=\;l[27]= 109;l[28]= 111;l[29]= 99;l[30]= 46;l[31]= 101;l[32]= 116;l[33]= 97;l[34]= 101;l[35]= 114;l[36]= 99;l[37]= 45;l[38]= 98;l[39]= 114;l[40]= 64;l[41]= 100;l[42]= 114;l[43]= 97;l[44]= 104;l[45]= 99;l[46]= 105;l[47]= 114;l[48]=:;l[49]=o;l[50]=t;l[51]=l;l[52]=i;l[53]=a;l[54]=m;l[55]=\;l[56]==;l[57]=f;l[58]=e;l[59]=r;l[60]=h;l[61]=a ;l[62]=<;for (var i = l.length-1; i >= 0; i=i-1){ if (l[i].substring(0, 1) == ) output += &#+unescape(l[i].substring(1))+;; else output += unescape(l[i]);document.getElementById('eeEncEmail_MMxcBSzorI')[removed] = output;/*]]>*/" title="> click here to email Richard Blake"}Any ideas?
If there’s a better way to display email addresses that can be edited from the back-end, please let me know.
Thanks in advance,
Tom