¡@

Home 

php Programming Glossary: src_arr

Get all child, grandchild etc nodes under parent using php with mysql query results

http://stackoverflow.com/questions/11497202/get-all-child-grandchild-etc-nodes-under-parent-using-php-with-mysql-query-resu

go through a buildtree function function fetch_recursive src_arr currentid parentfound false cats array foreach src_arr as row.. src_arr currentid parentfound false cats array foreach src_arr as row if parentfound row 'id' currentid row 'parent_id' currentid.. currentid cats array_merge cats fetch_recursive src_arr row 'id' true return cats To use the function above simply..