File size: 3.09Kb
<?php
$mt=microtime();
require('db.php');
require('nast.php');
require('shapka.php');
/////////////////
print $beginpage;
$result_count=mysql_query("SELECT count(*) from `user`");
$count=mysql_fetch_row($result_count);
$ontime=time()-350;
$res_onl=mysql_query("SELECT place from `user` WHERE `ldate`>$ontime");//Онлайн
$count1=mysql_num_rows($res_onl);
for($i=0; $i<$count1; $i++)
{
$place=mysql_fetch_assoc($res_onl);
@$oncount[$place['place']]++;
}
print $vydel."Добро пожаловать<br/>$vydel1";
$result=mysql_query("SELECT name,rid from `room` WHERE `status`<3 ORDER by `roomp` DESC");
if($str=='xhtml')
{
print '</div><form action="enter.php?str=xhtml" method="post"><div>
Ник:<br/> <input name="nick" maxlength="20" value="" title="nick"/><br/>
Транслит: <input type="checkbox" name="translit" value="1"/><br/><br/>
Пароль:<br/>
<input name="pass" maxlength="20" value="" title="password"/><br/><br/>
<select name="room">
<option value="9999">Прихожая ['.(intval(@$oncount['9999'])).']</option>
<option value="1021">Очко(21) ['.(intval(@$oncount['1021'])).']</option>
<option value="1022">Кости ['.(intval(@$oncount['1022'])).']</option>
<option value="1000">Кто где?</option>';
while($room=mysql_fetch_assoc($result))
{
print "<option value=\"$room[rid]\">$room[name] [".(intval(@$oncount[$room['rid']]))."]</option>";
}
print '<option value="1001">Интим ['.(intval(@$oncount['1001'])).']</option>
</select><br/>
<input class="ibutton" type="submit" value="Войти"/></div></form><div>';
}
else
{
print 'Ник:<br/> <input name="nick" maxlength="20" value="" title="nick"/><br/>
<select name="translit" multiple="true">
<option value="1">Транслитеровать</option>
</select><br/>
Пароль:<br/>
<input name="pass" maxlength="20" value="" title="password"/><br/><br/>
<select name="room">
<option value="9999">Прихожая ['.(intval(@$oncount['9999'])).']</option>
<option value="1021">Очко(21) ['.(intval(@$oncount['1021'])).']</option>
<option value="1022">Кости ['.(intval(@$oncount['1022'])).']</option>
<option value="1000">Кто где?</option>';
while($room=mysql_fetch_assoc($result))
{
print "<option value=\"$room[rid]\">$room[name] [".(intval(@$oncount[$room['rid']]))."]</option>";
}
print '<option value="1001">Интим ['.(intval(@$oncount['1001'])).']</option>
</select><br/>
<anchor title="go">Войти<go href="enter.php?str=wml" method="post">
<postfield name="nick" value="$(nick)"/>
<postfield name="pass" value="$(pass)"/>
<postfield name="room" value="$(room)"/>
<postfield name="translit" value="$(translit)"/>
</go></anchor><br/>';
}
print '---<br/>
<a href="ustav.php?str='.$str.'">Устав городка</a><br/>
<a href="regi.php?str='.$str.'">Регистрация</a><br/>
---<br/>';
$ontime=time()-350;
print "Сейчас в городке <a href=\"online.php?str=$str\">$count1</a> жителей<br/>";
print 'Всего жителей: '.$count[0].'<br />';
print $endpage;
print '<!-- '.(microtime()-$mt).' -->';
?>