<?php
defined('_JEXEC') or die('Restricted access!');

/**
 * Races View - Default Template
 *
 * JPodium is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License 2
 * as published by the Free Software Foundation.
 * 
 * JPodium 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 General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with JPodium; if not, write to the Free Software
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
 * 
 * @version $Id: default.php 245 2010-12-03 17:24:26Z detlefvolmer $
 * @author Detlef Volmer <webmaster@jpodium.de>
 * @package JPodiumFrontend
 * @subpackage Views
 * @copyright Copyright (C) Detlef Volmer www.jpodium.de
 * @license http://www.gnu.org/copyleft/gpl.html GNU/GPL
 */

echo JPodiumHTMLHelper::CreateComponentHeader('logo-jpodium.png', 300, 92);
echo JPodiumHTMLHelper::CreateLinkBar(_VIEW_RACES, $this->year, '', NULL);

if (empty($this->validRaceIDs))
	echo JPodiumHTMLHelper::CreateMessage(_JPO_NO_ENTRIES_IN_RACES_LIST);
else {
	echo '<div id="jpo_container">';
	foreach($this->validRaceIDs as $validRaceID) {
		if (array_key_exists($validRaceID, $this->resultTables)) {
			echo $this->raceHeaders[$validRaceID];
			echo $this->resultTables[$validRaceID];
		}
	}
	echo '</div>';		// jpo_container
}
echo JPodiumHTMLHelper::CreateComponentFooter();