
////////////////////////////////////////////
//                              ///
////////////////////////////////////////////

*****************************************************************************************************************************
1 .       .					                                                                *
2 .    (chmod, permission) 777 :                                                                 *
/files                                                                                                                      *
/screen                                                                                                                     *
/graftemp                                                                                                                   *
/book                                                                                                                       *
/mp3temp                                                                                                                    *
/temp                                                                                                                       *
3 .     http://_/upload/install.php                                                   *
4 .        ,     install.php   !!!*
//      update.php   !!!                                                          *
*****************************************************************************************************************************

  incfiles/func.php:
----------------------------

function provupl($catalog)
{
    $cat1 = mysql_query("select * from `upload` where type = 'cat' and id = '" . $catalog . "';");
    $cat2 = mysql_num_rows($cat1);
    $adrdir = mysql_fetch_array($cat1);
    if (($cat2 == 0) || (!is_dir("$adrdir[adres]/$adrdir[name]")))
    {
        echo "   <br/><a href='?'> </a><br/>";
        require_once ('../incfiles/end.php');
        exit;
    }
}

function upload($var)
{
global $realtime;
$old = $realtime - (3 * 24 * 3600);
$count_new = mysql_result(mysql_query("SELECT COUNT(`id`) FROM `upload` WHERE `time` > '" . $old . "' and `type`='file';"), 0);
$out = $count_new;

if ($var != 1)
    {
$count = mysql_result(mysql_query("SELECT COUNT(`id`) FROM `upload` WHERE `type`='file';"), 0);
if ($out > 0)
{$out = $count . "&nbsp;/&nbsp;<span class='red'><a href='upload/?act=new'>+" . $out . "</a></span>";}
    }
return $out;
}


pages/mainmenu.php:
----------------------

echo '<a href="upload/"></a> (' . upload() . ')<br />';

    :
---------------------------------

$total_upload = upload(1);
if ($total_upload > 0)
echo '<li><a href="upload/index.php?act=new"></a> (' . $total_upload . ')</li>';

        ( && !$total_upload):
//   ,  
if (!$total_news && !$total_forum && !$total_guest && !$total_gal && !$total_upload && !$total_lib)

________________
         Z3RO 