Advertisement
Guest User

Untitled

a guest
Sep 22nd, 2019
141
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 0.21 KB | None | 0 0
  1.  <?php $menu=file_get_contents("inc/main_nav.php");
  2.  
  3. $base=basename($_SERVER['PHP_SELF']); $menu=preg_replace("|<li><a href=\"".$base."\">(.*)</a></li>|U", "<li class=\"current\">$1</li>", $menu); echo $menu; ?>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement