PanelBar for FAQ ?

6 posts, 1 answers
  1. Peter
    Peter avatar
    97 posts
    Member since:
    May 2016

    Posted 18 Sep 2018 Link to this post

    Hello,

    for a database table 'FAQ' (with columns Question and Answer) I want use the PanelBar to show the faq. If I use https://demos.telerik.com/aspnet-core/panelbar/remote-data-binding then the Answers (the childs) ar not displayed. But this I could solved by a ajax call which write the response to an array 'data'.

    The childs are displayed as buttons. Can I display the child text as normal text?

    And can I render the child text as html for links, formatting ...?

    Dojo: https://dojo.telerik.com/OQusiTiJ

     

    Regards,

    Peter

     


  2. Peter
    Peter avatar
    97 posts
    Member since:
    May 2016

    Posted 18 Sep 2018 in reply to Peter Link to this post

    When can I edit my post???
    Admin, please change title to "PanelBar for FAQ?"

  3. Peter
    Peter avatar
    97 posts
    Member since:
    May 2016

    Posted 18 Sep 2018 Link to this post

    The 'answer' / 'child' text in the dojo has to large linespacing. How can I set to the 'normal' linespacing of the surrounding div?
  4. Answer
    Ivan Danchev
    Admin
    Ivan Danchev avatar
    2059 posts

    Posted 20 Sep 2018 Link to this post

    Hello Peter,

    By setting the items option of the root items (Q1, Q2, Q3) you are creating sub-items which why they act like buttons. Instead you could use the content option of the root items. I modified your example accordingly: dojo example. As far as I can tell this also resolves the line spacing issue.

    As for post editing, this functionality is currently not available for the users, but I updated the title.

    Regards,
    Ivan Danchev
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
  5. Peter
    Peter avatar
    97 posts
    Member since:
    May 2016

    Posted 21 Sep 2018 in reply to Ivan Danchev Link to this post

    Thank you, Ivan!

    This solve also an other issue:

    The included html-code: <a href="http://www.loremipsum.de/">Lorem ipsum</a> was not rendered.

    Now the link is shown!

    Best Regards,

    Peter

     

  6. Ivan Danchev
    Admin
    Ivan Danchev avatar
    2059 posts

    Posted 24 Sep 2018 Link to this post

    Hello Peter,

    I am glad the approach with using the content option worked out.

    As for the issue with the link in the original example you posted, there was a missing anchor closing tag:
    <a href="http://www.loremipsum.de/">Lorem ipsum</a>
    and also in order to show Html as item text the item's encoded option has to be set to false. Here's the original example, with these two changes added: dojo.


    Regards,
    Ivan Danchev
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
Back to Top