"]; foreach ($path as $current => $value) { $path = trim(str_replace("//", "/", "{$parent}/{$current}"), "/"); $result[] = "
  • "; if (is_string($value)) { $result[] = "{$current}"; continue; } $result[] = "{$current}"; $result[] = $self($self, $value, $path); $result[] = "
  • "; } $result[] = ""; return join("\n", $result); }; echo $render($render, $menu); ?>