¡@

Home 

php Programming Glossary: current_depth

Getting nested set model into a <ul> but hiding “closed” subtrees

http://stackoverflow.com/questions/7729173/getting-nested-set-model-into-a-ul-but-hiding-closed-subtrees

array 'name' '' 'depth' '' 'lft' '' 'rgt' '' current false current_depth 0 counter 0 result ' ul ' foreach tree as node node_depth node.. node 'name' node_id node 'category_id' if node_depth current_depth if counter 0 result . ' li ' elseif node_depth current_depth.. if counter 0 result . ' li ' elseif node_depth current_depth result . ' ul ' current_depth current_depth node_depth current_depth..