Copied to clipboard

Flag this post as spam?

This post will be reported to the moderators as potential spam to be looked at


These support forums are now closed for new topics and comments.
Please head on over to http://eureka.ucommerce.net/ for support.

  • Dmitrij Jazel 86 posts 179 karma points
    Jan 21, 2013 @ 00:06
    Dmitrij Jazel
    0

    Product description showing up in raw HTML

    Hej guys,

    I have a small problem here,

    I am calling this in product details razor macro I have for my product here...

    @product.LongDescription()

    What I am getting as a result is this (in the eventual frontend):

    <p>Lorem Ipsum is simply dummy text...</p>

    How do I get rid of html and style tags and just get a text from Product long descriotion?

    I feel that I have to "disable-output-escaping" maybe, but than how? :-)

     

    Regards,

    Dmitrij

  • David Brendel 792 posts 2970 karma points MVP 3x c-trib
    Jan 21, 2013 @ 13:30
    David Brendel
    0

    I think if you're working with razor all you have to do is to call the Html.Raw() method to convert the string in an HtmlString.

    Then the markup should be handled as markup and not as plain text.

  • Dmitrij Jazel 86 posts 179 karma points
    Jan 21, 2013 @ 19:32
    Dmitrij Jazel
    0

    Hej David,

    Yes, I did use Razor here... and it helped :-)

    Thanks alot for help!

    //Dmitrij

  • Søren Spelling Lund 1797 posts 2786 karma points
    Jan 21, 2013 @ 22:06
    Søren Spelling Lund
    0

    Thanks again, David, for helping out :)

Please Sign in or register to post replies

Write your reply to:

Draft