This is a migrated thread and some comments may be shown as answers.

PanelBar for FAQ ?

5 Answers 72 Views
PanelBar
This is a migrated thread and some comments may be shown as answers.
Peter
Top achievements
Rank 1
Peter asked on 18 Sep 2018, 02:30 PM

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

 


5 Answers, 1 is accepted

Sort by
0
Peter
Top achievements
Rank 1
answered on 18 Sep 2018, 02:33 PM

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

0
Peter
Top achievements
Rank 1
answered on 18 Sep 2018, 04:03 PM
The 'answer' / 'child' text in the dojo has to large linespacing. How can I set to the 'normal' linespacing of the surrounding div?
0
Accepted
Ivan Danchev
Telerik team
answered on 20 Sep 2018, 11:55 AM
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.
0
Peter
Top achievements
Rank 1
answered on 21 Sep 2018, 09:00 AM

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

 

0
Ivan Danchev
Telerik team
answered on 24 Sep 2018, 02:22 PM
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.
Tags
PanelBar
Asked by
Peter
Top achievements
Rank 1
Answers by
Peter
Top achievements
Rank 1
Ivan Danchev
Telerik team
Share this question
or