Hi there,
we are currently developing an asp.net mvc3 aaplication. What we need to do, is to give users the ability, to input the text for an email-message. Users can add placeholders to the message like <#User.Name#>. I've implemented CKEditor and set " entities: false, basicEntities: false, htmlEncodeOutput: false,"
If I use the placeholder in simple text, everything is working perfect.
But I'm getting Problems when using a placeholder inside an anchor-tag:
<a href="<#User.AccessLink#>"><#User.AccessLink#></a>
This is getting rendered to:
<a href="<#User.AccessLink#>"><#User.AccessLink#></a>
Since this is what is getting postet to the server, the server isn't able to recognize the placeholder and won't replace it with the correct data. I'm having a hard time getting this solved so I thaught I should ask some experts.
Thanks for reading and hopefully for your replies
UPDATE!!!
Found the solution to this Problem.
dataProcessor.toDataFormat = function(html, fixForBody){ //find all tag-elements var matches = html.match(/&#{0,1}[a-z0-9]+;/ig); //go through each match and replace the encoded characters if (matches!=null) { for (match in matches) { replacedString=matches[match]; replacedString = matches[match].replace(/>/g,'>'); replacedString = replacedString.replace(/</g,'<'); replacedString = replacedString.replace(/&/g,'&'); html = html.replace(matches[match],replacedString); } } return html; };
Only took a day Bye