Example #1
0
            $cache->clear($val['account_name'], ROOT_DIR . '/cache/players/');
            $links[$val['account_name']] = $config['td'] . '/uc/accounts/' . $val['account_id'] . '/api/1.9/?source_token=Intellect_Soft-WoT_Mobile-unofficial_stats';
        }
        multiget($links, $res, $config, prepare_stat(), $roster, $lang);
        //print_r($result);
        unset($links);
        // Unlocking DB now
        lockout_mysql();
        //$cache->set('res', $res,ROOT_DIR.'/cache/players');
    }
}
// In $res array stored player statistic.
$sql = "SHOW TABLES FROM `" . $dbname . "` LIKE 'col_tank_%';";
$q = $db->prepare($sql);
if ($q->execute() == TRUE) {
    $col_tables = reform($q->fetchAll());
} else {
    die(show_message($q->errorInfo(), __LINE__, __FILE__, $sql));
}
$sql = "SELECT DISTINCT up FROM `col_players` ;";
$q = $db->prepare($sql);
if ($q->execute() == TRUE) {
    $col_check = count($q->fetchAll());
} else {
    die(show_message($q->errorInfo(), __LINE__, __FILE__, $sql));
}
$multiclan = read_multiclan();
$multiclan_main = multi_main($multiclan);
foreach ($multiclan as $clan) {
    if ($clan['id'] != $config['clan']) {
        $multiclan_info[$clan['id']] = $cache->get('get_last_roster_' . $clan['id'], 0);
Example #2
0
 * @author      $Author: Edd $
 * @copyright   2011-2011 Edd - Aleksandr Ustinov
 * @link        http://wot-news.com
 * @package     Clan Stat
 * @version     $Rev: 1.2.6 $
 *
 */
define('ROOT_DIR', dirname(__FILE__));
include_once ROOT_DIR . '/function/config.php';
include_once ROOT_DIR . '/nosql/' . $language . '.php';
include_once ROOT_DIR . '/nosql/config_' . SERVER . '.php';
$begin_time = microtime(true);
if (MYSQL == 'on' && MYSQL_ERROR != 'on') {
    include_once ROOT_DIR . '/function/mysql.php';
    $players = $db->query("SELECT * FROM players;")->fetch();
    $tables = reform($db->query("SHOW TABLES FROM " . $dbname . " LIKE 'tank\\_%';")->fetchAll());
} else {
    $tables = array();
}
include_once ROOT_DIR . '/function/html_dom.php';
include_once ROOT_DIR . '/function/curl.php';
include_once ROOT_DIR . '/function/mcurl.php';
if (file_exists(ROOT_DIR . '/function/rating.php')) {
    include_once ROOT_DIR . '/function/rating.php';
}
include_once ROOT_DIR . '/function/func.php';
include_once ROOT_DIR . '/function/get.php';
//print_r($config);
//$newss = get_last_roster();
if (is_valid_url($config['td']) == true) {
    $new = get_player(CLAN, $config);