Вход Регистрация
Файл: ubiznes.mobi/inc/firms/about.php
Строк: 112
<?
$firms
=mysql_fetch_assoc(mysql_query("SELECT * FROM `firms` WHERE `id` = '".intval($_GET['about'])."' LIMIT 1"));
if(
$firms['id']==$firm['id']){header("location:/?firms");exit;}
$rating_need pow(2.71,$firms['level']+1) * 1000;
include_once
'inc/firms/forums.php'// форум
$q=mysql_query("SELECT * FROM `firms_user` WHERE `id_firm` = '$firms[id]'  ORDER BY `status` ASC,`rating` DESC");
if(
mysql_result(mysql_query("SELECT COUNT(*) FROM `firms_build` WHERE `id_f` = '$firms[id]'"),0)==0){
    
mysql_query("INSERT INTO `firms_build` SET `id_f` = '$firms[id]'"); header("location:.?firms&about=$firms[id]");exit;
}
$builds=mysql_fetch_assoc(mysql_query("SELECT * FROM  `firms_build` WHERE `id_f` = '$firms[id]' LIMIT 1"));
?>
    <div class="prof">
        <table style="width:100%" cellspacing="0" cellpadding="0" valign="top"><tbody><tr>
                <td width="20%" align="center"><img src="/images/style/gorod.png"></td>
                <td width="60%">
                    <?php echo hsc($firms['name']); ?><br>
                    <small>Основание: <?php echo date('d.m.Y',$firms['time_create']); ?></small>
                </td>
                <td width="20%" align="center">
                    <img src="/images/style/gorod.png">
                </td>
            </tr></tbody></table>
        <div class="line-2"></div>
        <span class="right"><img src="/images/style/gorod.png" width="16" height="16"> Рабочих: <?=$firms['work_all'];?></span>
        <img src="/images/style/star_on.png" width="16" height="16">  Уровень:  <?=$firms['level'];?><div class="line-2"></div>
        <img src="/images/style/star_on.png" width="16" height="16"> Опыт: <?php echo rating($firms['rating']); ?> / <?php echo rating($rating_need); ?>
        <div class="line-2"></div>
        <?    echo'<center>';
            echo
'
            <span class="t_13" style="padding: 3px 10px 0px 6px;">
                <span class="count_roof"> '
.$builds['bank'].' </span>
                <img src="/images/'
.($builds['bank']==0?'null':'/build/bank').'.png" height="30" width="30">
            </span>'
;echo'
            <span class="t_13" style="padding: 3px 10px 0px 6px;">
                <span class="count_roof"> '
.$builds['ads'].' </span>
                <img src="/images/'
.($builds['ads']==0?'null':'/build/ads').'.png" height="30" width="30">
            </span>'
;echo'
            <span class="t_13" style="padding: 3px 10px 0px 6px;">
                <span class="count_roof"> '
.$builds['nalog'].' </span>
                <img src="/images/'
.($builds['nalog']==0?'null':'/build/nalog').'.png" height="30" width="30">
            </span>'
;
            echo
'</center>';
        
?>
        <div class="line-2"></div>
            <img src="/images/style/mb.png" width="16" height="16"> Вложения:
            <span class="right">
                <img src="/images/style/b.png" width="16" height="16"> <?php echo razd($firms['baks']); ?>
                <img src="/images/style/money.png" width="16" height="16">  <?php echo razd($firms['money']); ?>
            </span>
    </div>
    <? echo'<div class="sp1 clrt1 t_norm "> '.img_icons(16,16,'documents').'  <a href=/?firms&about='.$firms['id'].'&forums>Форум фирмы</a> </div>';?>
    <div class="text-2">
        <img src="/images/style/manmini_0_0.png" height="16" width="16"> Бизнесменов: <b> <?php echo mysql_num_rows($q); ?> </b> из <span>10 </span> <img src="/images/style/manmini_0_0.png" height="16" width="16">
    </div>
<?
while($post=mysql_fetch_assoc($q)){
    
$ank=mysql_fetch_assoc(mysql_query("SELECT * FROM `user` WHERE `id` = '$post[id_user]' LIMIT 1"));
    if(
$post['status']==1$st='Директор';
    if(
$post['status']==2$st='зам. директора';
    if(
$post['status']==3$st='Менеджер';
    if(
$post['status']==4$st='рабочий';
    
$user_work+=mysql_result(mysql_query("SELECT SUM(`works`) FROM `business_user` WHERE `id_user` = '$post[id_user]'"),0);
    
?>
    <div class="sp1 clrt1 t_norm ">
        <span class="t_13 float-left" style="padding: 3px 10px 0px 6px;">
            <?php echo user_icon($post['id_user']); ?>
        </span>
        <?php echo nc($post['id_user']); ?>
        <span><?=img_ic(16,16,'style/star_on').' '.rating($post['rating']); ?> </span> <br>
        <span class="c1 t_13">
                <font color="yellow"><?=$st;?><?=($ank['date_last']>=(time()-900)?'<font color="lime">в сети</font>':'<font color="gray">был в сети: '.time_left($time-$ank['date_last']).'</font>');?> </font>
        </span>  
    </div>
    <?php
}
include_once
'sys/foot.php';
Онлайн: 1
Реклама