Import Html with link issue

2 posts, 0 answers
  1. Sistema PRI
    Sistema PRI avatar
    6 posts
    Member since:
    Oct 2008

    Posted 29 May Link to this post

    Hi,

    I have a html on my database:

    Prezado(a) Délio Tomaz(), <br>
            O Documento \Measurement\Cronograma Financeiro.xlsx sob sua responsabilidade vencerá no dia 30/05/2017.
            <br>
            <br><a href='http://slocal:11100//PrixDocxDowdnloxad?Token=xxxxxx>Link Text</a><br>
       Atenciosamente,
            <br>
            Equipe PRIMANAGER

     

    I am loading this Html with HtmlFormatProvider. But when the richtext loads the Html I got the issue attached (imagemtelerik.png). Note that the link tag is broken. All text was read as link and it loses it formatting.

     

    If I take out the inner text from <a> tag, all works fine (the link isn't show, but my html is OK)(sem titulo.png).

    The code to read the HTML:

    var provider = new HtmlFormatProvider();
    var document = provider.Import(html);

     

    Best 

    Delio

     

     

  2. Peshito
    Admin
    Peshito avatar
    524 posts

    Posted 31 May Link to this post

    Hi,

    Thank you for providing the html snippet. Seems like you are missing the closing quote for the href attribute. Updating the code as below should work fine.
    Prezado(a) Délio Tomaz(), <br>
            O Documento \Measurement\Cronograma Financeiro.xlsx sob sua responsabilidade vencerá no dia 30/05/2017.
    <br>
    <br><a href='http://slocal:11100//PrixDocxDowdnloxad?Token=xxxxxx'>Link Text</a><br>
       Atenciosamente,
    <br>
            Equipe PRIMANAGER
    Hope this helps.

    Regards,
    Peshito
    Progress Telerik
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top