<?php
require("mysql.php");
require_once 'filter.php';

$titel = 'Übersicht - Fotos';
$styles = '<link href="/sf/f/registration/registration.css" rel="stylesheet" type="text/css">
<link href="/sf/m/buttons/buttons.css" rel="stylesheet" type="text/css"><link href="/sf/f/index/index.css" rel="stylesheet" type="text/css"><link href="/sf/m/boxes/boxes.css" rel="stylesheet" type="text/css"><link href="/sf/m/forms/forms.css" rel="stylesheet" type="text/css"><link href="/sf/f/photos/photos.css" rel="stylesheet" type="text/css"><link href="/sf/m/tables/tables.css" rel="stylesheet" type="text/css"><link href="/sf/m/uploader/uploader.css" rel="stylesheet" type="text/css"><link href="/sf/f/photos/photos-rate.css" rel="stylesheet" type="text/css">';

$inhalt .= '
<div class="photo"> 
<div class="noh1"></div> 
<div class="pg"> 
 
<div class="toplists"> 
 
<div class="yui-g"> 
<div class="yui-u first"> 
<div class="box zero small"> 
<div class="hd"> 
<div class="tl"></div> 
<div class="tr"></div> 
<div class="tm"></div> 
<div class="m"><div class="mi">
<div class="h h2"><div class="hbegin"></div><h2>Top weiblich,
 
14 &ndash; 15
 
</h2></div> 
</div></div> 
</div> 
<div class="bd fade bd-fade"> 
<div class="m"> 
<div class="mi">';
$aa = mysql_query("select photo, name, ratingZahl, age, gender from accounts where photo != '' and gender='2' and age >= '14' and age < '16' and name != 'James' order by ratingZahl desc limit 2");
while($a = @mysql_fetch_array($aa)) {
$inhalt .= '<div class="centerInHalfWidth"> 
<a href="photos-profile.php?id='.$a[name].'" class="nodecoration"> 
<img src="pics/photos/m/'.$a[photo].'.jpg" /> 
<br/> 
'.$a[name].'
</a> 
<br class="">'.$a[ratingZahl].'
</div> 
';
}
$inhalt .= '<div class="clear"></div> 
</div> 
</div> 
<div class="bl"></div> 
<div class="br"></div> 
<div class="bm"></div> 
</div> 
</div> 
</div> 
<div class="yui-u"> 
<div class="box zero small"> 
<div class="hd"> 
<div class="tl"></div> 
<div class="tr"></div> 
<div class="tm"></div> 
<div class="m"><div class="mi">
<div class="h h2"><div class="hbegin"></div><h2>Top männlich,
 
14 &ndash; 15
 
</h2></div> 
</div></div> 
</div> 
<div class="bd fade bd-fade"> 
<div class="m"> 
<div class="mi"> ';
$bb = mysql_query("select photo, name, ratingZahl, age, gender from accounts where photo != '' and gender='1' and age >= '14' and age < '16' and name != 'James' order by ratingZahl desc limit 2");
while($b = @mysql_fetch_array($bb)) {
$inhalt .= '<div class="centerInHalfWidth"> 
<a href="photos-profile.php?id='.$b[name].'" class="nodecoration"> 
<img src="pics/photos/m/'.$b[photo].'.jpg" /> 
<br/> 
'.$b[name].'
</a> 
<br class="">'.$b[ratingZahl].'
</div> 
';
}
$inhalt .= '<div class="clear"></div> 
</div> 
</div> 
<div class="bl"></div> 
<div class="br"></div> 
<div class="bm"></div> 
</div> 
</div> 
</div> 
</div> 
 
<div class="yui-g"> 
<div class="yui-u first"> 
<div class="box zero small"> 
<div class="hd"> 
<div class="tl"></div> 
<div class="tr"></div> 
<div class="tm"></div> 
<div class="m"><div class="mi">
<div class="h h2"><div class="hbegin"></div><h2>Top weiblich,
 
16 &ndash; 17
 
</h2></div> 
</div></div> 
</div> 
<div class="bd fade bd-fade"> 
<div class="m"> 
<div class="mi">  ';
$cc = mysql_query("select photo, name, ratingZahl, age, gender from accounts where photo != '' and gender='2' and age >= '16' and age < '18' and name != 'James' order by ratingZahl desc limit 2");
while($c = @mysql_fetch_array($cc)) {
$inhalt .= '<div class="centerInHalfWidth"> 
<a href="photos-profile.php?id='.$c[name].'" class="nodecoration"> 
<img src="pics/photos/m/'.$c[photo].'.jpg" /> 
<br/> 
'.$c[name].'
</a> 
<br class="">'.$c[ratingZahl].'
</div> 
';
}
$inhalt .= '<div class="clear"></div> 
</div> 
</div> 
<div class="bl"></div> 
<div class="br"></div> 
<div class="bm"></div> 
</div> 
</div> 
</div> 
<div class="yui-u"> 
<div class="box zero small"> 
<div class="hd"> 
<div class="tl"></div> 
<div class="tr"></div> 
<div class="tm"></div> 
<div class="m"><div class="mi">
<div class="h h2"><div class="hbegin"></div><h2>Top männlich,
 
16 &ndash; 17
 
</h2></div> 
</div></div> 
</div> 
<div class="bd fade bd-fade"> 
<div class="m"> 
<div class="mi">  ';
$dd = mysql_query("select photo, name, ratingZahl, age, gender from accounts where photo != '' and gender='1' and age >= '16' and age < '18' and name != 'James' order by ratingZahl desc limit 2");
while($d = @mysql_fetch_array($dd)) {
$inhalt .= '<div class="centerInHalfWidth"> 
<a href="photos-profile.php?id='.$d[name].'" class="nodecoration"> 
<img src="pics/photos/m/'.$d[photo].'.jpg" /> 
<br/> 
'.$d[name].'
</a> 
<br class="">'.$d[ratingZahl].'
</div> 
';
}
$inhalt .= '<div class="clear"></div> 
</div> 
</div> 
<div class="bl"></div> 
<div class="br"></div> 
<div class="bm"></div> 
</div> 
</div> 
</div> 
</div> 
 
<div class="yui-g"> 
<div class="yui-u first"> 
<div class="box zero small"> 
<div class="hd"> 
<div class="tl"></div> 
<div class="tr"></div> 
<div class="tm"></div> 
<div class="m"><div class="mi">
<div class="h h2"><div class="hbegin"></div><h2>Top weiblich,
 
18 &ndash; 21
 
</h2></div> 
</div></div> 
</div> 
<div class="bd fade bd-fade"> 
<div class="m"> 
<div class="mi">  ';
$ee = mysql_query("select photo, name, ratingZahl, age, gender from accounts where photo != '' and gender='2' and age >= '18' and age < '22' and name != 'James' order by ratingZahl desc limit 2");
while($e = @mysql_fetch_array($ee)) {
$inhalt .= '<div class="centerInHalfWidth"> 
<a href="photos-profile.php?id='.$e[name].'" class="nodecoration"> 
<img src="pics/photos/m/'.$e[photo].'.jpg" /> 
<br/> 
'.$e[name].'
</a> 
<br class="">'.$e[ratingZahl].'
</div> 
';
}
$inhalt .= '<div class="clear"></div> 
</div> 
</div> 
<div class="bl"></div> 
<div class="br"></div> 
<div class="bm"></div> 
</div> 
</div> 
</div> 
<div class="yui-u"> 
<div class="box zero small"> 
<div class="hd"> 
<div class="tl"></div> 
<div class="tr"></div> 
<div class="tm"></div> 
<div class="m"><div class="mi">
<div class="h h2"><div class="hbegin"></div><h2>Top männlich,
 
18 &ndash; 21
 
</h2></div> 
</div></div> 
</div> 
<div class="bd fade bd-fade"> 
<div class="m"> 
<div class="mi">  ';
$ff = mysql_query("select photo, name, ratingZahl, age, gender from accounts where photo != '' and gender='1' and age >= '18' and age < '22' and name != 'James' order by ratingZahl desc limit 2");
while($f = @mysql_fetch_array($ff)) {
$inhalt .= '<div class="centerInHalfWidth"> 
<a href="photos-profile.php?id='.$f[name].'" class="nodecoration"> 
<img src="pics/photos/m/'.$f[photo].'.jpg" /> 
<br/> 
'.$f[name].'
</a> 
<br class="">'.$f[ratingZahl].'
</div> 
';
}
$inhalt .= '<div class="clear"></div> 
</div> 
</div> 
<div class="bl"></div> 
<div class="br"></div> 
<div class="bm"></div> 
</div> 
</div> 
</div> 
</div> 
 
<div class="yui-g"> 
<div class="yui-u first"> 
<div class="box zero small"> 
<div class="hd"> 
<div class="tl"></div> 
<div class="tr"></div> 
<div class="tm"></div> 
<div class="m"><div class="mi">
<div class="h h2"><div class="hbegin"></div><h2>Top weiblich,
 
22 &ndash; 29
 
</h2></div> 
</div></div> 
</div> 
<div class="bd fade bd-fade"> 
<div class="m"> 
<div class="mi"> 
 ';
$gg = mysql_query("select photo, name, ratingZahl, age, gender from accounts where photo != '' and gender='2' and age >= '22' and age < '30' and name != 'James' order by ratingZahl desc limit 2");
while($g = @mysql_fetch_array($bb)) {
$inhalt .= '<div class="centerInHalfWidth"> 
<a href="photos-profile.php?id='.$g[name].'" class="nodecoration"> 
<img src="pics/photos/m/'.$g[photo].'.jpg" /> 
<br/> 
'.$g[name].'
</a> 
<br class="">'.$g[ratingZahl].'
</div> 
';
}
$inhalt .= '
<div class="clear"></div> 
</div> 
</div> 
<div class="bl"></div> 
<div class="br"></div> 
<div class="bm"></div> 
</div> 
</div> 
</div> 
<div class="yui-u"> 
<div class="box zero small"> 
<div class="hd"> 
<div class="tl"></div> 
<div class="tr"></div> 
<div class="tm"></div> 
<div class="m"><div class="mi">
<div class="h h2"><div class="hbegin"></div><h2>Top männlich,
 
22 &ndash; 29
 
</h2></div> 
</div></div> 
</div> 
<div class="bd fade bd-fade"> 
<div class="m"> 
<div class="mi"> 
 ';
$hh = mysql_query("select photo, name, ratingZahl, age, gender from accounts where photo != '' and gender='1' and age >= '22' and age < '30' and name != 'James' order by ratingZahl desc limit 2");
while($h = @mysql_fetch_array($hh)) {
$inhalt .= '<div class="centerInHalfWidth"> 
<a href="photos-profile.php?id='.$b[name].'" class="nodecoration"> 
<img src="pics/photos/m/'.$h[photo].'.jpg" /> 
<br/> 
'.$h[name].'
</a> 
<br class="">'.$h[ratingZahl].'
</div> 
';
}
$inhalt .= '<div class="clear"></div> 
</div> 
</div> 
<div class="bl"></div> 
<div class="br"></div> 
<div class="bm"></div> 
</div> 
</div> 
</div> 
</div> 
 
<div class="yui-g"> 
<div class="yui-u first"> 
<div class="box  small"> 
<div class="hd"> 
<div class="tl"></div> 
<div class="tr"></div> 
<div class="tm"></div> 
<div class="m"><div class="mi">
<div class="h h2"><div class="hbegin"></div><h2>Top weiblich,
 
ab 30
 
</h2></div> 
</div></div> 
</div> 
<div class="bd fade bd-fade"> 
<div class="m"> 
<div class="mi">  ';
$ii = mysql_query("select photo, name, ratingZahl, age, gender from accounts where photo != '' and gender='2' and age >= '30' and name != 'James' order by ratingZahl desc limit 2");
while($i = @mysql_fetch_array($ii)) {
$inhalt .= '<div class="centerInHalfWidth"> 
<a href="photos-profile.php?id='.$i[name].'" class="nodecoration"> 
<img src="pics/photos/m/'.$i[photo].'.jpg" /> 
<br/> 
'.$i[name].'
</a> 
<br class="">'.$i[ratingZahl].'
</div> 
';
}
$inhalt .= '<div class="clear"></div> 
</div> 
</div> 
<div class="bl"></div> 
<div class="br"></div> 
<div class="bm"></div> 
</div> 
</div> 
</div> 
<div class="yui-u"> 
<div class="box  small"> 
<div class="hd"> 
<div class="tl"></div> 
<div class="tr"></div> 
<div class="tm"></div> 
<div class="m"><div class="mi">
<div class="h h2"><div class="hbegin"></div><h2>Top männlich,
 
ab 30
 
</h2></div> 
</div></div> 
</div> 
<div class="bd fade bd-fade"> 
<div class="m"> 
<div class="mi">  ';
$jj = mysql_query("select photo, name, ratingZahl, age, gender from accounts where photo != '' and gender='1' and age >= '30' and name != 'James' order by ratingZahl desc limit 2");
while($j = @mysql_fetch_array($jj)) {
$inhalt .= '<div class="centerInHalfWidth"> 
<a href="photos-profile.php?id='.$j[name].'" class="nodecoration"> 
<img src="pics/photos/m/'.$j[photo].'.jpg" /> 
<br/> 
'.$j[name].'
</a> 
<br class="">'.$j[ratingZahl].'
</div> 
';
}
$inhalt .= '<div class="clear"></div> 
</div> </div>';

$inhalt .= '<div class="bl"></div><div class="br"></div><div class="bm"></div></div></div></div></div></div></div></div></div>';

echo str_replace(array('<?url?>','<?inhalt?>', '<?titel?>', '<?fotonavi?>', '<?registrieren?>', '<?styles?>', '<?fotos?>'),array($_SERVER[SERVER_NAME], $inhalt, $titel, $fotonavi, $registrieren, $styles, $fotos),implode("",file("sf/b/style.tpl")));
?>