Source

Selador / menue_portal.php

Full commit
<script src="scripts/de.js" type="text/javascript"></script>

<?php

/* infoframe.php - Front-end code for in-portal menu
 *
 * Copyright (C) 2006, 2007, 2008 Kevin Read, Simone Schaefer
 *
 * This file is part of Selador, a browser-based fantasy strategy game
 *
 * This program is distributed under the terms of the GNU Affero General Public License.
 *
 *
 *   Selador is free software: you can redistribute it and/or modify
 *   it under the terms of the GNU Affero General Public License as published by
 *   the Free Software Foundation, either version 3 of the License, or
 *   any later version.
 *
 *   Selador is distributed in the hope that it will be useful,
 *   but WITHOUT ANY WARRANTY; without even the implied warranty of
 *   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *   GNU Affero General Public License for more details.
 *
 *   You should have received a copy of the GNU Affero General Public License
 *   along with Selador.  If not, see <http://www.gnu.org/licenses/>.
 **/
require_once("header_extern.php");
echo '</head>
	<body class="inhalt">
		<div id="zentriert">
			<div id="banner">';
			
if (!function_exists ("dynamic_link_outer"))
{
	function dynamic_link_outer ($url, &$localurl)
	{
		if (strstr ($localurl, $url))
			return  "<a  href=\"".$url."\">";
		else
			return "<a href=\"".$url."\">";
	}
}

$loctime = localtime();

$tmp_localfile = basename ($_SERVER['PHP_SELF']);
?>

<div id='bannertitle'>
	<a href="uebersicht.php"><img src="styles/new/schriftzug.png" title="&Uuml;bersicht"></a>
</div>

<div id="menu">
	<ul class="level1">
		<?php 
		$classes = array(
					"index" => ' class="menue"', 
					"usersetup" => ' class="menue"',
					"getting_involved" => ' class="menue"',
					"halloffame" => ' class="menue"'
				);
		if (strstr($_SERVER['PHP_SELF'], 'index.php') || strstr($_SERVER['PHP_SELF'], 'portal.php'))
			$classes["index"] = ' class="menue-aktiv"';
		if (strstr($_SERVER['PHP_SELF'], 'usersetup.php'))
			$classes["usersetup"] = ' class="menue-aktiv"';
		if (strstr($_SERVER['PHP_SELF'], 'halloffame.php'))
			$classes["halloffame"] = ' class="menue-aktiv"';
		if (strstr($_SERVER['PHP_SELF'], 'getting_involved.php'))
			$classes["getting_involved"] = ' class="menue-aktiv"';
		
		//$class= ' class="submenu"';
		?>
		
		<?php
		//$f = (int)$_GET['f'];
		if (strstr($_SERVER['PHP_SELF'], 'portal.php') || strstr($_SERVER['PHP_SELF'], 'index.php'))
		{
			$class = "subactive";
			$id = " id=\"cfnavbar\"";
		}
		else
			$class = "submenu";
		?>
		
		<li class="<?php echo $class ?>"><a href="portal.php?f=1" <?php echo $classes['index'] ?>>Welten betreten</a>
		

		<div <?php echo $id ?>>
			<ul class="level2">
				<li id="leftcorner">&nbsp;</li>
				<li ><a href="portal.php?f=1"<?php if ($f == 1) echo ' class="activetab"' ?>>Deine Helden</a></li>
				<li  ><a href="portal.php?f=2"<?php if ($f == 2) echo ' class="activetab"' ?>>Aktuelle Welten</a></li>
				<li ><a href="portal.php?f=3"<?php if ($f == 3) echo ' class="activetab"' ?>>Abgelaufene Welten</a></li>
				<li ><a href="portal.php?f=4"<?php if ($f == 4) echo ' class="activetab"' ?>>Andere Spieler sitten</a></li>
				<li id="rightcorner">&nbsp;</li>
			</ul>
		</div>
		
		</li>
		<li><a href="usersetup.php" <?php echo $classes['usersetup'] ?>>Einstellungen</a></li>
		<li><a href="halloffame.php" <?php echo $classes['halloffame'] ?>>Hall of fame</a></li>
		<li><a href="getting_involved.php"<?php echo $classes['getting_involved'] ?>>Mithelfen!</a></li>
		<li><a href="http://forum.selador.de" target="_blank">Forum</a></li>
		<li><a href="masterlogout.php"<?php echo $classes['about'] ?>>Ausloggen</a></li>
	</ul>
</div>
</div>