Lines Matching refs:ns

102         //skips i=0 because that becomes main $ns
104 //skips i=0 because that becomes main $ns
123 $ns = $matched_ns_lvl[1];
128 $ns = $nsStrs[0];
132 $ns = $this->parseNs($ns);
261 } elseif ($gen_id == 'ns') {
262 $identifier = sprintf("%u", crc32($ns));
302 $ns, //0
327 'navbar' => $navbar, //add current ns to subNSs, for initial load
408 $ns = $data[0];
442 if (!isset($ns)) {
443 $ns = ':';
445 //add ns of current page to let open these nodes (within the $ns), open only 1 level.
453 //resolve ns and subns's relative to current wiki page (instead of sidebar)
454 $ns = $this->parseNs($ns, $INFO['id']);
461 $html = $this->buildHtmlIndexmenu($ns, $js_dTreeOpts, $sort, $opts, $jsVersion);
465 $html = str_replace('{{ns}}', cleanID($ns), $html);
477 $renderer->doc .= (empty($ns) ? $conf['title'] : nons($ns)) . " index\n\n";
488 * @param string $ns
499 private function buildHtmlIndexmenu($ns, $js_dTreeOpts, $sort, $opts, $jsVersion)
505 $nodes = $search->search($ns, $opts);
512 $ns = str_replace('/', ':', $ns);
516 $output_js .= $this->builddTree($nodes, $ns, $js_dTreeOpts, $js_name, $opts['max']);
519 $output_js .= $this->buildFancyTree($js_name, $ns, $opts, $sort);
544 private function buildFancyTree($js_name, $ns, $opts, $sort)
559 'ns' => $ns,
573 * @param string $ns requested namespace
584 private function builddTree($nodes, $ns, $js_dTreeOpts, $js_name, $max)
593 // Render requested ns as root
597 if (empty($ns) && !empty($headpage)) {
600 $title = Search::getNamespaceTitle($ns, $headpage, $hns);
602 if (empty($ns)) {
605 $title = $ns;
634 $out .= $js_name . ".add('" . idfilter(cleanID($ns), false) . "',0,-1," . json_encode($title);
751 * @param string $ns namespaceid
752 * @param bool $id page id to resolve $ns relative to.
757 public function parseNs($ns, $id = false)
764 if ($ns == '..') {
765 $ns = ":";
767 $ns = "$ns:arandompagehere";
769 $ns = getNs($resolver->resolveId($ns));
770 return $ns === false ? '' : $ns;