<!--/***************** DO NOT REMOVE! *********************/---->
<!--/*   Author: Nevezhyn Evgeny  Date : 10/01/2003       */---->
<!--/*             All Rights Reserved ...                */---->
<!--/*        Supplied by WTN-WDYL Team `2004             */---->
<!--/***************** DO NOT MODIFY! *********************/---->

<?php
echo "<html><head>";
include("var.php");
echo "<META HTTP-EQUIV=\"Expires\" Content=\"Mon, 28 Mar 1999 00:00:01 GMT\"><META HTTP-EQUIV=\"Cache-Control\" CONTENT=\"No-Cache\">";
include("top.php");
@$db=mysql_connect($bdhost,$bdlogin,$bdpass);
@mysql_select_db($bdname,$db);
$result = @mysql_query("SELECT ID,name,city,category,status FROM $textable WHERE status='ok' order by date DESC LIMIT 7");
if (@mysql_num_rows($result) == 0) {
echo "<center><b>Нет новых анкет</b>";
}
else {
echo "<div align=right><table class=vfbord bgcolor=#330000 width=90%><tr><td width=100%><p align=center>Новые анкеты:</td></tr></table><table width=90% class=vfbord3 border=0>";
while ($myrow=mysql_fetch_array($result)) {
$ID=$myrow["ID"];
$name=$myrow["name"];
$city=$myrow["city"];
$category=$myrow["category"];
echo "<tr><td class=vfbord><a href=list.php?g=$category&link=$ID>$name</a>&nbsp;-&nbsp;$category&nbsp;-&nbsp;г.$city</td></tr>";
}
echo "</table></div><br><br><center>";
}
$bazef = file("category.dat");
for ($o=0;$o<count($bazef);$o++)
{//1
$result = @mysql_query("SELECT ID,name,email,city,metro,telephone,othercon,birth,CURRENT_DATE,(YEAR(CURRENT_DATE)-YEAR(birth)) - (RIGHT(CURRENT_DATE,5)<RIGHT(birth,5)) AS age,height,weight,bust,body,edu,hair,eyes,category,tr,appricehour,appricenight,homepricehour,homepricenight,comment,foto1,foto2,foto3,foto4,foto5,aid,date,reiting,status FROM $textable WHERE category = '$bazef[$o]' and status='ok' and reiting>0 order by reiting DESC LIMIT 1");
if (@mysql_num_rows($result) != 0) {
while ($myrow=@mysql_fetch_array($result)) 
{
$ID=$myrow["ID"];
$name=$myrow["name"];
$city=$myrow["city"];
$metro=$myrow["metro"];
$telephone=$myrow["telephone"];
$height=$myrow["height"];
$weight=$myrow["weight"];
$bust=$myrow["bust"];
$age=$myrow["age"];
$tr=$myrow["tr"];
$category=$myrow["category"];
$comment=$myrow["comment"];
$appricehour=$myrow["appricehour"];
$appricenight=$myrow["appricenight"];
$homepricehour=$myrow["homepricehour"];
$homepricenight=$myrow["homepricenight"];
$foto1=$myrow["foto1"];
$foto2=$myrow["foto2"];
$foto3=$myrow["foto3"];
$foto4=$myrow["foto4"];
$foto5=$myrow["foto5"];
$status=$myrow["status"];
if ($foto1 != "") {$fotourl=$foto1;}
else {if ($foto2 != "") {$fotourl=$foto2;}
else {if ($foto3 != "") {$fotourl=$foto3;}
else {if ($foto4 != "") {$fotourl=$foto4;}
else {if ($foto5 != "") {$fotourl=$foto5;}
}}}}
if ($metro != "") {$mline="Метро:&nbsp;$metro";}
if ($metro == "") {$mline="";}
if ($appricehour != 0) {$pr1line="<li>Апартаменты:<br><b>$appricehour$</b>/час<br><b>$appricenight$</b>/ночь";}
if ($appricehour == 0) {$pr1line="";}
if ($homepricehour != 0) {$pr2line="<li>Выезд:<br><b>$homepricehour$</b>/час<br><b>$homepricenight$</b>/ночь";}
if ($homepricehour == 0) {$pr2line="";}
if ($commenttrue == 'TRUE') {$commentline="<a href=comment.php?ID=$ID><b>Отзывы</b></a>";}
else {$commentline="";}
echo ("
<table width=97% class=vfbord3>
<tr><td width=28% valign=top class=vfbord bgcolor=#330000><p align=center><b>$name</b></td>
<td width=23% valign=top class=vfbord bgcolor=#330000><p align=center><b>$category</b></td>
<td width=23% valign=top class=vfbord bgcolor=#330000><p align=center>$mline</td>
<td width=26% valign=top class=vfbord bgcolor=#330000><p align=center><b>г.$city</b></td></tr>
<tr><td width=28% valign=middle rowspan=3 class=vfbord><p align=center><img src=$photodir$fotourl border=0 width=150></td>
<td width=23% valign=middle class=vfbord><p align=center>Информация:</td>
<td width=23% valign=middle class=vfbord><p align=center>Услуги:</td>
<td width=26% valign=middle class=vfbord><p align=center>Условия:</td></tr>
<tr><td width=23% valign=top class=vfbord>          
<ul><br><li>Возраст:&nbsp;<b>$age</b>&nbsp;&nbsp;<br><li>Рост:&nbsp;<b>$height</b><br><li>Вес:&nbsp;<b>$weight</b><br><li>Бюст:&nbsp;<b>$bust</b></td>
<td width=23% valign=top class=vfbord align=center>$tr</td>
<td width=26% valign=top class=vfbord><ul><br>
$pr1line
$pr2line
</ul></td></tr>
<tr><td width=72% valign=top colspan=3 class=vfbord><p align=center>$comment<br><br></td></tr>
<tr><td width=28% valign=top class=vfbord><p align=center>&nbsp</td>
<td width=23% valign=top class=vfbord><p align=center><a href=list.php?g=$category&link=$ID><b>Подробнее &gt;&gt;</b></a></td>
<td width=23% valign=top class=vfbord><p align=center>$commentline</td>
<td width=26% valign=top class=vfbord><p align=center><a href=# OnClick=window.open('vote.php?ID=$ID','PopUp','menubar=no,toolbar=no,scrollbars=no,location=yes,status=no,width=400,height=200')><b>Голосовать</b></a></td></tr>
</table><br><br>
");    
}
}
}//1
include("down.php");
?>