public function __destruct() { if (!empty($this->logUpdates)) { $this->backup(); $this->logUpdates = array(); } parent::__destruct(); }
public function __destruct() { if (!is_null(self::$fp)) { @fclose(self::$fp['fp']); self::$fp = null; } }
<?php /** * 删除日志表 * @author wanghui@uuzu.com * @date 2015-4-27 */ require dirname(__FILE__) . '/../global.php'; TenYear::getInstance(); ini_set('default_socket_timeout', -1); Com_AdCache::factory()->set_timeout(0); $objGameLog = new Com_GameLog(); Com_Timer::register_datetime(array($objGameLog, 'drop_table_name'), "04:00"); if ($argv[1] == 'd') { $objGameLog->drop_table_name(); exit; } Com_Timer::start();
public function run() { $log = new Com_GameLog(); $log->create_table_name(); }