I asked a question on stackoverflow about binding a xml data file to a Kendo UI Menu.
http://stackoverflow.com/questions/23998479/binding-xml-data-to-kendo-ui-menu-dynamically
I was wondering if Kendo supports binding to a xml file dynamically. If so, could you also create multiple menus with hierarchy structures?
http://stackoverflow.com/questions/23998479/binding-xml-data-to-kendo-ui-menu-dynamically
I was wondering if Kendo supports binding to a xml file dynamically. If so, could you also create multiple menus with hierarchy structures?
7 Answers, 1 is accepted
0
Hi Brandon,
The Kendo UI Menu does not support data binding, so it is not possible to bind an XML service to the menu. You can manually create a data structure that you can pass to the menu, as shown in this example:
http://demos.telerik.com/kendo-ui/menu/images
Regards,
Kiril Nikolov
Telerik
The Kendo UI Menu does not support data binding, so it is not possible to bind an XML service to the menu. You can manually create a data structure that you can pass to the menu, as shown in this example:
http://demos.telerik.com/kendo-ui/menu/images
Regards,
Kiril Nikolov
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0

Brandon
Top achievements
Rank 1
answered on 12 Jun 2014, 01:38 PM
Thank you Kiril for the quick response! So, is there an alternative way which will allow me to create a menu dynamically?
0
Hi Brandon,
As the menu does not support data binding there is no built-in solution to create such. If you check this demo you can see that the menu is initialized with JavaScript and not pure HTML, so if you parse your XML and create similar structure, then you might achieve something like dynamic menu creation.
Regards,
Kiril Nikolov
Telerik
As the menu does not support data binding there is no built-in solution to create such. If you check this demo you can see that the menu is initialized with JavaScript and not pure HTML, so if you parse your XML and create similar structure, then you might achieve something like dynamic menu creation.
Regards,
Kiril Nikolov
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
0

Ashok
Top achievements
Rank 1
answered on 22 Jan 2015, 01:18 PM
yes.... same problem i have.have got solution for that
0

Hemant
Top achievements
Rank 1
answered on 06 May 2015, 10:07 PM
Hi Ashok, what is the solution you have used? Please share.
0

Hemant
Top achievements
Rank 1
answered on 07 May 2015, 02:46 AM
Hi Nikolov
Can you please post a sample of how you would insert the data from the parsed XML into the dataSource that is inside the kendoMenu structure?
<script>
$("#menu-images").kendoMenu({
dataSource: [
0
Hello Hemant,
An example of using a dataSource in a Kendo UI Menu is available here:
http://docs.telerik.com/kendo-ui/api/javascript/ui/menu#configuration-dataSource
Please note that it only supports JavaScript array of object, and not XML.
Regards,Kiril Nikolov
Telerik
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!