<style>
.tsznagytop{
	background: url(/public/img/galeria/picture_frame_sprite.png) -729px 0 no-repeat;
	height: 11px;
	width: 729px;
}
.tsznagycenter{
	background: url(/public/img/galeria/picture_frame_sprite.png) -1458px 0 repeat-y;
	padding: 7px 19px 0px 19px;
}
.tsznagycenter img{
	margin: 0px 5px 0px 0px;
	float: left;
	max-width: 692px;
	min-width: 692px;
}
</style>

<div style="text-align: center">
<br>
<?
$header_suffix = $this->uri->segment(3);

if($header_suffix=="amator" && !file_exists('public/img/tervezzszabadon/tervezz_szabadon_header_amator.jpg'))
	$header_suffix="amature";
elseif($header_suffix=="felhasznalo" && !file_exists('public/img/tervezzszabadon/tervezz_szabadon_header_felhasznalo.jpg'))
	$header_suffix="user";

if($header_suffix!="")$header_suffix = "_".$header_suffix;

if(eng())$header_suffix = $header_suffix."_ENG";
?>
<img src="http://www.archline.hu/public/img/tervezzszabadon/tervezz_szabadon_header<?=$header_suffix?>.jpg" alt="Tervezz szabadon!">
</div>

<div id="baloldal">

<?		/* Kis képek */		?>
<?$i = $ui = 1; $u = 0; $elozo = "";?>
<?foreach($kepek as $kep):?>
<?$kepadatok = explode('_-_',$kep); ?>
<?if($kepadatok[0]==$elozo):?>
	<?$ui++;?>
<?else:?>
	<?$ui = 1; $u++;?>
	<div class="clear"></div>
<?endif;?>
<div style="float: left; width: 182px; text-align: center;">
<p style="text-align: center;"><?=$u?>. <?=str_replace(array('_',"Pal Zsuzsanna"),array(' ',"Pál Zsuzsanna"),$kepadatok[0])?></p>
<a href="/<?=$dir?><?=$kep?>" class="fancy" rel="csop1" title="<?=$kep?>">
	<img src="/<?=$dir?>thumbs/<?=$kep?>" alt="" style="margin: 0px 2px 0px 0px;" />
	</a>
</div>
<?$i++;?>
<?$elozo = $kepadatok[0];?>
<?endforeach;?>
<div class="clear"></div>


<?		/* Nagy képek */		?>
<?$i = $ui = 1; $u = 0; $elozo = "";?>
<?foreach($kepek as $kep):?>
<?$kepadatok = explode('_-_',$kep); ?>
<?if($kepadatok[0]==$elozo):?>
	<?$ui++;?>
<?else:?>
	<?$ui = 1; $u++;?>
	<div class="clear"></div>
<?endif;?>
<div class="hkheadertop"></div>
<div class="hkkeret">
	<table width="100%"><tr>
	<td>
		<div class="gal-cim2 feherbetu" style="margin-bottom: 10px; color: #fff !important;"><?=$u?>.</div>
	</td>
	<td align="right">
		<div class="gal-cim2 vcard" style="margin-bottom: 10px; text-align: right;">
			<?=lang('hk_keszitette')?>: <span class="feherbetu fn" style="color: #fff;"><?=str_replace(array('_',"Pal Zsuzsanna"),array(' ',"Pál Zsuzsanna"),$kepadatok[0])?></span>
		</div>
	</td>
	</tr></table>
</div>
<div class="hkheaderbottom"></div>

<div class="tsznagytop"></div>
<div class="tsznagycenter">
	<a href="/<?=$dir?><?=$kep?>" class="fancy" title="<?=$kep?>">
	<img src="/<?=$dir?><?=$kep?>" alt="" />
	</a><span style="font-size: 5px;">&nbsp;</span>
</div>
<div style="background: url(/public/img/galeria/picture_frame_sprite.png) no-repeat; height: 13px; width: 729px;"></div>
<?$i++;?>
<?$elozo = $kepadatok[0];?>
<?endforeach;?>

</div>


<?		/* Eredmeny */		?>
<div id="jobboldal" style="padding-top: 10px;">
	<?/*<img src="/public/img/galeria/ek_banner<?if(hun()):?>_hun<?else:?>_eng<?endif;?>.png" alt="<?=lang('hk')?>" />*/?>
	
	<div class="hkheadersmalltop"></div>
	<div class="hkkeretsmall">
		<?if( time() > strtotime('2013-12-17 12:00:00') ):?>
			<?=lang('tsz_vegleiras')?>
		<?else:?>
			<?=lang('tsz_leiras')?>
		<?endif;?>
	</div>
	<div class="hkheadersmallbottom"></div>
	
	<div class="hkheadersmalltop"></div>
	<div class="hkkeretsmall">
		<div class="gal-cim2"><?=lang('ek_szavall')?></div>
		<table>
		<tr>
			<td></td>
			<td><?//=lang('ek_szavazat')?></td>
		</tr>
		
		<?
		$palyazok = array();
		foreach($kepek as $kep){
			$kepadatok = explode('_-_',$kep);
			if(!isset($kepadatok[0],$palyazok[$kepadatok[0]])){
				$palyazok[$kepadatok[0]] = 1;
				continue;
			}
			
			$palyazok[$kepadatok[0]]++;
		}
		?>
		<? $honapok = lang('honapok'); $hoi = $ossz=0; ?>
		<?$i=1;?>
		<?foreach($palyazok as $user => $darab):?>
		<tr>
			<?$tmpsorszam="";?>
			<?for($xx=1;$xx<=$darab;$xx++):?><? $tmpsorszam .= $i."/".$xx.", " ?><?endfor;?>
			<td><?=$i.". ".str_replace(array('_',"Pal Zsuzsanna"),array(' ',"Pál Zsuzsanna"),$user)?> </td>
			<td>
				<?if($szavazas[$hoi]->kep==$user):?>
					<?//=$szavazas[$hoi]->darab?>
					<?$ossz+=$szavazas[$hoi]->darab;$hoi++;?>
				<?else:?>
					0
				<?endif;?>
			</td>
		<?$i++;?>
		</tr>
		<?endforeach;?>
		
		<?/*<tr><td><?=lang('ek_osszesen')?>: </td><td><?=$ossz?></td></tr>*/?>
		</table>
		<?if($valasz):?><p style="margin-bottom: 0px; padding-bottom: 0px;"><?=$valasz?></p><?endif;?>
	</div>
	<div class="hkheadersmallbottom"></div>
	
	
	<div class="hkheadersmalltop"></div>
	<div class="hkkeretsmall">
		<?if(hun()):?>
			<?if($this->uri->segment(3)=="amator"):?>
				<a href="/tervezz-szabadon/szavazas/felhasznalo">Felhasználó kategória</a>
			<?else:?>
				<a href="/tervezz-szabadon/szavazas/amator">Amatőr kategória</a>
			<?endif;?>
		<?else:?>
			<?if($this->uri->segment(3)=="amature"):?>
				<a href="/feel-free-to-design/voting/user">Professional category</a>
			<?else:?>
				<a href="/feel-free-to-design/voting/amature">Amature category</a>
			<?endif;?>
		<?endif;?>
	</div>
	<div class="hkheadersmallbottom"></div>
	
</div>