Ejemplo n.º 1
0
            $data = $BILL->GetTarifAccts($tarif, $fdate, $tdate, 1);
            $tdata = $BILL->GetTarifData($tarif);
            $accts = NULL;
            $accts[0]["traffic"] = $data["traffic"];
            $accts[0]["time"] = $data["time"];
            $accts[0]["packet"] = $tdata["packet"];
        }
        $cnt = count($accts);
        if (!isset($param)) {
            $param = "";
        }
        if ($param == "traffic") {
            for ($k = 0; $k < $cnt; ++$k) {
                $data[$k] = $accts[$k]["traffic"];
                $labels[$k] = $accts[$k]["packet"] . " (" . bytes2mb($accts[$k]["traffic"]) . " Мб)";
                $fdate_s = date_dmy(strtotime($fdate));
                $tdate_s = date_dmy(strtotime($tdate));
                $params[14] = "Статистика тарифов по траффику за период " . $fdate_s . " - " . $tdate_s;
            }
        } else {
            for ($k = 0; $k < $cnt; ++$k) {
                $data[$k] = $accts[$k]["time"];
                $labels[$k] = $accts[$k]["packet"] . " (" . gethours($accts[$k]["time"]) . ":" . getmins($accts[$k]["time"]) . ":" . getsecs($accts[$k]["time"]) . ")";
                $fdate_s = date_dmy(strtotime($fdate));
                $tdate_s = date_dmy(strtotime($tdate));
                $params[14] = "Статистика тарифов по времени за период " . $fdate_s . " - " . $tdate_s;
            }
        }
        break;
}
$gr->Draw($params, $data, $labels);
Ejemplo n.º 2
0
    global $usr_id, $CURRENT_USER;
    $USR = new CUsers($DIRS["users_data"], $DIRS["users_list"], $DIRS["users_private"], $DIRS["users_groups"], $DIRS["users_online"]);
    $USR->SetSeparators($GV["sep1"], $GV["sep2"]);
    $list = $USR->GetUsers();
    for ($i = 0; $i < count($list); ++$i) {
        $ud = $list[$i];
        $all_users[$i] = $list[$i]["id"];
        $users_info['login'][$i] = $ud["login"];
        $users_info['pass'][$i] = $ud["passwd"];
        $users_info['nick'][$i] = $ud["nick"];
        $users_info['city'][$i] = $ud["city"];
        $users_info['sex'][$i] = make_gender_str($ud["gender"]);
        $users_info['email'][$i] = $ud["email"];
        $users_info['url'][$i] = $ud["url"];
        $users_info['id'][$i] = $all_users[$i];
        $users_info['date'][$i] = date_dmy($ud["regdate"]);
        $users_info['rang'][$i] = $ud["rang"];
        $fud = get_forum_user_data($all_users[$i]);
        $users_info['count'][$i] = $fud["count"];
        //echo($list[$i]["id"]."==($i)".$CURRENT_USER["id"]."<br>");
        if ($list[$i]["id"] == $CURRENT_USER["id"]) {
            $usr_id = $i;
        }
        $users_info['raiting'][$i] = $ud["raiting"];
        $users_info['rights'][$i] = $ud["level"];
        $users_info['sign'][$i] = $ud["signature"];
        $users_info['info'][$i] = $ud["info"];
    }
} else {
    die("MODULE 'USERS' NOT FOUND :( Forum willnt work!");
}
Ejemplo n.º 3
0
 case "today":
     $accts = $BILL->GetTodayUsersAccts($sort, 0, $gid);
     $wday = date("w");
     if ($wday == 0) {
         $wday = 6;
     }
     $head = "Статистика по пользователям за " . $wdaysto[$wday - 1] . ", " . date("d") . " " . $monthsof[date("n") - 1] . "" . date(" Y года");
     break;
 case "month":
     $accts = $BILL->GetMonthUsersAccts($sort, 0, $gid);
     $head = "Статистика по пользователям за " . $months[date("n") - 1] . " " . date("Y") . " года:<br>\n   <small>(по состоянию на " . date("d") . " " . $monthsof[date("n") - 1] . ")</small>";
     break;
 case "week":
     $accts = $BILL->GetWeekUsersAccts($sort, 0, $gid);
     get_current_week(&$b, &$a, 0);
     $head = "Статистика по пользователям за текущую неделю:<br><small>(" . date_dmy(strtotime($b)) . " - " . date_dmy(strtotime($a)) . ")</small>";
     break;
 case "sessions":
     if ($mod == "show") {
         if (!isset($groupby)) {
             $groupby = "";
         }
         if ($daysel[0] == "null") {
             $daysel1 = 1;
         } else {
             $daysel1 = $daysel[0];
         }
         if ($monsel[0] == "null") {
             $monsel1 = 1;
         } else {
             $monsel1 = $monsel[0];
Ejemplo n.º 4
0
          <tr><td width=50%>
          URL:</td><td><?php 
                                OUT(make_url_str($udata["url"]));
                                ?>
          </td></tr>

          <tr><td width=50%>
          ICQ:</td><td><?php 
                                OUT(make_icq_str($udata["icq"]));
                                ?>
          </td></tr>

          <tr><td width=50%>
          Зарегистрирован:</td><td><?php 
                                OUT(date_dmy($udata["regdate"]));
                                ?>
          </td></tr>

          <?php 
                                if ($udata["country"]) {
                                    ?>
          <tr><td width=50%>
          Страна:</td><td><?php 
                                    OUT($udata["country"]);
                                    ?>
          </td></tr>
          <?php 
                                }
                                ?>
Ejemplo n.º 5
0
 case "today":
     $accts = $BILL->GetTodayUsersAccts($sort, 0, $gid);
     $wday = date("w");
     if ($wday == 0) {
         $wday = 6;
     }
     $head = "Статистика по пользователям за " . $wdaysto[$wday - 1] . ", " . date("d") . " " . $monthsof[date("n") - 1] . "" . date(" Y года");
     break;
 case "month":
     $accts = $BILL->GetMonthUsersAccts($sort, 0, $gid);
     $head = "Статистика по пользователям за " . $months[date("n") - 1] . " " . date("Y") . " года:<br>\n   <small>(по состоянию на " . date("d") . " " . $monthsof[date("n") - 1] . ")</small>";
     break;
 case "week":
     $accts = $BILL->GetWeekUsersAccts($sort, 0, $gid);
     get_current_week(&$b, &$a, 0);
     $head = "Статистика по пользователям за текущую неделю: (" . date_dmy(strtotime($b)) . " - " . date_dmy(strtotime($a)) . ")";
     break;
 case "sessions":
     $head = "Статистика по сессиям за период " . $fdate . " - " . $tdate;
     if (isset($user) && $user != "") {
         $accts = $BILL->GetUserSessions($user, $fdate, $tdate);
     } elseif ($groupby == "users") {
         $accts = $BILL->GetUsersSessions($fdate, $tdate);
     } else {
         $accts = $BILL->GetSessions($fdate, $tdate);
     }
     break;
 case "tarifs":
     $head = "Статистика по тарифам за период " . $fdate . " - " . $tdate;
     if ($tarif == "!all!") {
         $accts = $BILL->GetTarifsAccts($fdate, $tdate);