Would be possible to build a nested menu with one mysql table? I have been making a table having the following structure but I’m having problem to build up the query
ID | Menu | parent | position | active
1 test 0 1 1
2 test2 1 2 1
….
MySQL is not the best DB when it comes to storing hierarchical data. It doesn’t really have native support for it. So you can either write a recursive function in php that pulls each nested menu out on demand (okay if there are only a few, else the constant round trips to the db really kill app performance) or you can do something like this:
http://explainextended.com/2009/03/17/hierarchical-queries-in-mysql/