Current is now a class.

git-svn-id: https://develop.svn.wordpress.org/trunk@475 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Matt Mullenweg 2003-10-26 19:31:13 +00:00
parent ae278e6d7e
commit aa2843398c
1 changed files with 5 additions and 5 deletions

View File

@ -11,16 +11,16 @@ foreach ($menu as $item) {
if ($continue) { if ($continue) {
$item = explode("\t", $item); $item = explode("\t", $item);
// 0 = user level, 1 = file, 2 = name // 0 = user level, 1 = file, 2 = name
if (substr($PHP_SELF, -6) == substr($item[1], -6)) $class = ' id="current"'; if (substr($PHP_SELF, -7) == substr($item[1], -7)) $class = ' class="current"';
if ($user_level >= $item[0]) echo "\n\t<li><a href='{$item[1]}'$class>{$item[2]}</a></li>"; if ($user_level >= $item[0]) echo "\n\t<li><a href='{$item[1]}'$class>{$item[2]}</a></li>";
} }
} }
?> ?>
<li><a href="javascript:profile(<?php echo $user_ID ?>)">My&nbsp;Profile</a></li> <li><a href="javascript:profile(<?php echo $user_ID ?>)">My Profile</a></li>
<li><a href="<?php echo "$siteurl/$blogfilename"; ?>">View&nbsp;site</a></li> <li><a href="<?php echo "$siteurl/$blogfilename"; ?>">View site</a></li>
<li class="last"><a href="<?php echo $siteurl ?>/b2login.php?action=logout">Logout&nbsp;(<?php echo stripslashes($user_nickname) ?>)</a></li> <li class="last"><a href="<?php echo $siteurl ?>/b2login.php?action=logout">Logout (<?php echo stripslashes($user_nickname) ?>)</a></li>
</ul> </ul>
<h2 id="top"><?php echo $title; ?></h2> <h2><?php echo $title; ?></h2>