Portal Engine Questions on portal engine and web parts.
Version 7.x > Portal Engine > HTML in a CartItemSelector View modes: 
User avatar
Member
Member
16vMonkey - 5/1/2013 6:10:12 AM
   
HTML in a CartItemSelector
Is it possible to add HTML in the AddToCartText text?

<uc1:CartItemSelector id="addItem" runat="server" SKUID='<%# EvalInteger("SKUID") %>' SKUEnabled='<%# EvalBool("SKUEnabled") %>' AddToCartText="Add to Cart" ShowWishlistLink="false" ShowUnitsTextBox="false" ShowProductOptions="false"/>

User avatar
Kentico Legend
Kentico Legend
Brenden Kehren - 5/1/2013 7:53:18 AM
   
RE:HTML in a CartItemSelector
Better question is, have you tried yet? If so and it fails, I'd wonder if the control doesn't HTMLEncode the button text. Any webpart/control I create, I make notes in the property if I allow HTML or not. Seems like some of the base webparts/controls restrict it but most don't. Would be nice to be consistent.

User avatar
Member
Member
16vMonkey - 5/1/2013 8:03:26 AM
   
RE:HTML in a CartItemSelector
yeah tried it but it just renders the html as text :(

User avatar
Kentico Legend
Kentico Legend
Brenden Kehren - 5/1/2013 8:23:08 AM
   
RE:HTML in a CartItemSelector
Then take a look in the source control's code and see if that property has the HTMLEncode method wrapped around it. If so, you could remove it. Keep in mind the security implecations if you do so. Also keep in mind this modifiction for future upgrades and hot fix applications.

User avatar
Member
Member
16vMonkey - 5/2/2013 10:30:20 AM
   
RE:HTML in a CartItemSelector
Thanks FroggEye, I've passed it onto someone who knows more about coding - i'm more on the frontend and transformation side of things.

User avatar
Member
Member
lwhittemore-emh - 9/4/2013 8:20:12 AM
   
RE:HTML in a CartItemSelector
I was able to add html to the text if that helps.
AddToCartLinkText="<i class='icon-shopping-cart'></i> Add to cart"