Advertisement
Guest User

Untitled

a guest
Jun 24th, 2017
47
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. function create_menu(&$tree, $id) {
  2. $html = '';
  3. if (isset($tree[$id]['children'])) {
  4. foreach ($tree[$id]['children'] as $t) {
  5. $html .= '<li>';
  6. $html .= "<a href='content/show/{$t['id']}' title='{$t['title']}'>";
  7. $html .= $t['title'];
  8. $html .= "</a>";
  9. $html .= '</li>';
  10. }
  11. } else {
  12. $html .= '<li></li>';
  13. }
  14. return $html;
  15. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement