		<!-- **************************** DENNY VYPIS NAVSTEV *****************************-->
		<div id="melodia_div">
		<table width="100%" cellpadding="0" cellspacing="0">
		<?php
			$page_limit = 15;
			$query = "SELECT * FROM mobile_navstev_dnes ORDER BY ID DESC limit 0, $page_limit";
			$result = $dba->GetResult($query);
			$query2 = "SELECT * FROM mobile_dload_dnes ORDER BY ID DESC limit 0, $page_limit";
			$result2 = $dba->GetResult($query2);
			$i = -1;
			$priem_navstev = 0;
			$priem_stranok = 0;
			$priem_stiahnuti = 0;
			$priem_dni = 14;
			while ($row=mysql_fetch_array($result))
			{
				$row2=mysql_fetch_array($result2);
				$i++;
				if($i>0 && $i<=$priem_dni)
				{
					$priem_navstev += $row["navstev"];
					$priem_stranok += $row["stranok"];
					$priem_stiahnuti += $row2["navstev"];
				}
				echo "<tr><td>".$row["datum"].": </td><td>".$row["navstev"]." návštev</td><td>".$row["stranok"]." stránok</td><td>online: ".$row["online"]."</td><td>".$row2["navstev"]." stiahnutí</td></tr>";
			}
			echo "<tr><td class=\"riadok_top_border\" height='15'></td><td></td><td></td><td></td><td></td></tr>";
			$priem_navstev = round($priem_navstev/$priem_dni, 2);
			$priem_stranok = round($priem_stranok/$priem_dni, 2);
			$priem_stiahnuti = round($priem_stiahnuti/$priem_dni, 2);
			$rec_fields = array('navstev', 'online', 'stranok');
			foreach ($rec_fields as $rec_field)
			{
				$_REC[$rec_field] = $dba->GetOne3("SELECT max($rec_field) FROM mobile_navstev_dnes");
			}
			$_REC['stiahnuti'] = $dba->GetOne3("SELECT max(navstev) FROM mobile_dload_dnes");
			echo "<tr><td class=\"riadok_top_border\">Priemery za $priem_dni dní:</td><td> $priem_navstev n/d </td><td> $priem_stranok s/d </td><td></td><td> $priem_stiahnuti s/d </td></tr>";
			echo "<tr><td class=\"riadok_top_border\">Rekordy:</td><td> ".$_REC['navstev']." návštev</td><td> ".$_REC['stranok']." stránok</td><td> ".$_REC['online']." online</td><td> ".$_REC['stiahnuti']." stiahnutí</td></tr>";
			unset($rec_fields);
		?>
		</table>
		</div>