Portal Engine Questions on portal engine and web parts.
Version 6.x > Portal Engine > Using Quote marks in a Transformation View modes: 
User avatar
Member
Member
paul.truman-sunmed.co - 10/26/2012 9:53:38 AM
   
Using Quote marks in a Transformation
Hey, I'm trying to using a compare statement in a transformation (so if the field = orderform then it shows the data) but I want to use the label text as a link. the only problem I have is that I don't know how to use " in the text (to render the <a href="#">).

Does anyone know how to do this? This is the code I am using in the transformation:

<%# IfCompare(Eval("DocumentCategory"),"orderform", "", "< a href='" + Eval("DocumentLink") + "'>" + Eval("DocumentTitle") + "</a>" ) %>

Any help would be appreciated :)

User avatar
Kentico Developer
Kentico Developer
kentico_ivanat - 10/28/2012 9:12:26 AM
   
RE:Using Quote marks in a Transformation
Hi,

this:

"< a href='" + Eval("DocumentLink") + "'>"

should be replaced by this:

"< a href=\" + Eval("DocumentLink") + \"'>"

It may be working now.

Best regards,
Ivana Tomanickova