<?php
/**
* @version		3.0.0
* @package		JomLand TicketCenter
* @copyright	Copyright (C) 2010 JomLand.com. All rights reserved.
* @link 		www.jomland.com
* @license		GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
*/
 // no direct access
defined('_JEXEC') or die('Restricted access');
?>
<?php if ($this->menuparams->get('show_page_title', 1)): ?>
<div class="componentheading<?php echo $this->escape($this->menuparams->get('pageclass_sfx')); ?>">
<h2><?php echo $this->escape($this->menuparams->get('page_title')); ?></h2>
</div>
<?php endif; ?>

<div class="contentpane<?php echo $this->escape($this->menuparams->get('pageclass_sfx')); ?>">

<h3><?php echo $this->city->city_name?></h3>
<?php
 	
	if ($this->city->state_id){
		if ($this->params->get('display_state') && $this->city->state_id){
			$state_link = JRoute::_('index.php?option=com_jlticketcenter&view=venues&state='.$this->city->state_id.'&Itemid='.$this->itemid);
			$state = JHTML::link($state_link, $this->city->state_name);
		}else{
			$state = $this->city->state_name;
		}
	}
	
	if ($this->params->get('display_country')>0){
		if ($this->params->get('display_country')==2){
			$country_link = JRoute::_('index.php?option=com_jlticketcenter&view=venues&country='.$this->city->country_id.'&Itemid='.$this->itemid);
			$country = ',&nbsp;&nbsp;'.JHTML::link($country_link, $this->city->country);
		}else{
			$country = ',&nbsp;&nbsp;'.$this->city->country;
		}
	}
	if (!empty($state)){
		echo $state;
	} 
	if (!empty($country)){
		echo $country;
	}
?>
<?php
if ($this->venues){ ?>
<ul>
<?php 	foreach ($this->venues as $venue){

		$venue_link = JROUTE::_('index.php?option=com_jlticketcenter&view=event&venue='.$venue->id.'&Itemid='.$this->itemid);
		$venue_name = JHTML::link($venue_link, $venue->venue_name);
?>
		<li><?php echo $venue_name;?></li>
		
	<?php };// end foreach	?>
</ul>
<?php 
}else{
	echo JText::_('Venues haven\'t found') .'<br>';
}?>

</div>
