I have a script and would like to know if someone could look at these 2 snippets and see they could change the output currently I get this /index.php?dir=accounting/ Would like to change this to be /plr-articles/accounting/ PART 1 global $config, $subdir; $exploded = explode('/', $subdir); $c = count($exploded) - 1; $temp = '<a class="autoindex_a" href="' . $_SERVER['PHP_SELF'] . '?dir=">' . Url::html_output(substr(str_replace('/', ' / ', $config -> __get('base_dir')), 0, -2)) . '</a>/ '; for ($i = 0; $i < $c; $i++) { $temp .= '<a class="autoindex_a" href="' . $_SERVER['PHP_SELF'] . '?dir='; for ($j = 0; $j <= $i; $j++) { $temp .= Url::translate_uri($exploded[$j]) . '/'; } $temp .= '">' . Url::html_output($exploded[$i]) . '</a> / '; PHP: PART 2 } global $words, $config, $subdir; $link = ' <a class="autoindex_a" href="' . $_SERVER['PHP_SELF'] . '?dir=' . Url::translate_uri($subdir) . '">' . Url::html_output($dir) . '</a> '; $this -> path_nav = $words -> __get('search results for') . $link . $words -> __get('and its subdirectories'); $this -> contents = $this -> matches; unset($this -> matches); } PHP: I would imagine I could replace the ?dir= with a word but it would still leave me with the index.php part. Thanks in advance
There is probably a better way but why not just to $link=str_replace('index.php?dir=','plr-articles/', $link); or something like that.
Replace: $temp .= '<a class="autoindex_a" href="' . $_SERVER['PHP_SELF'] . '?dir='; PHP: With: $temp .= '<a class="autoindex_a" href="/plr-articles/'; PHP: ??