Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 1 of 1
06-14-2005, 10:44 AM #1
- Join Date
- Jun 2005
- Thanked 0 Times in 0 Posts
Generating Tigra DHTML navigation menu items syntax from DB
I have installed "Tigra" dynamic navigation menu, and now it will be necessary , that the menu structure can be generated dynamically from mysql.
The syntax (to be generated) required for DTML structure is like:
var MENU_ITEMS = [ ['Home','http://www.your-site.com/'], ['Level 0 Item 1', null, null, ['Level 1 Item 0', 'another.html'], ['Level 1 Item 1'], ['Level 1 Item 2'], ['Level 1 Item 3'], ], ];
The problem is, how to generate this code correctly dynamically. I have tried many kinds of while-loops, but I just can't get close tags "]," placed correctly
I hope you understood what I am trying to do,
Is there anybody who have any ideas to solve this problem?