Hi Everyone..
I'm trying to get the data from table (select id, parent, name, orders from table) where all the data form a hiearchy with the parent. (so eg: 5, 6 categories are child of 3 and child 3 is child of 1).
I've using MVC method. so I will use function(recursive at the moment) to get data in array. Also, I need to print those hierchical data in unordered list in view. I've done it but its not doing exactly how i want (when printing arrays.. sometimes li is not closing or etc).
So can I get some idea to create data hin hierchical order and display them in list.
if anyone has done this and has got a code, would be so so so great..
thanks in ad.
Array to print in unordered list
Moderator: General Moderators
-
WebbieDave
- Forum Contributor
- Posts: 213
- Joined: Sun Jul 15, 2007 7:07 am
Re: Array to print in unordered list
Can you post what you've done so far?kuikel wrote:I've done it but its not doing exactly how i want