File size: 1.16Kb
<?
session_start();
$title="Статистика\n";
include ("header.php");
$_SESSION['pid']=$_GET['pid'];
if ($mod="exit") { unset($_SESSION['login']); unset($_SESSION['pass']); }
echo $div["header"];
echo "Сатистика партнерки";
echo $div["end"];
echo $div["ten"];
$q = mysql_query("select * from uzvers;");
$reg=mysql_num_rows($q);
echo "Всего партнеров: <b>$reg</b>";
$q = mysql_query("select * from uzvers where `allmonth`>'0';");
$reg=mysql_num_rows($q);
while ($field=mysql_fetch_array($q))
{
$w=$field['allmonth'];
$all=$all+$w;
}
echo "<br/>Активных: <b>$reg</b><br/>";
echo "На счету у партнеров : <b>$all</b> $ <br/> ";
$q = mysql_query("select * from uzvers where `opl`>'0';");
$reg=mysql_num_rows($q);
while ($field=mysql_fetch_array($q))
{
$w=$field['opl'];
$all1=$all1+$w;
$vsego=$all1+$all;
}
echo "Выплачено: <b>$all1</b> $<br/>";
echo "Всег заработали: <b>$vsego</b> $<br/><br/> <img src=\"pics/st.gif\" alt=\"*\"/>";echo "<a href=\"index.php?".session_name()."=".session_id()."\">Назад</a><br/>";
echo $div["end"];
include ("footergl.php");
?>