コード例 #1
0
ファイル: Debug.php プロジェクト: alexndreazevedo/iplayer
 public static function setDebug($log, $tab = null)
 {
     if (intval($tab) > 0) {
         $tab = Player_Utils::getSeparator(self::getTab(), $tab);
     }
     $log = $tab . $log;
     if (self::getLog() == null) {
         self::setLog(Player_Utils::getSeparator('=', 70));
         self::setLog('DOWNLOAD LOG - ' . (Player_Utils::getInterface() ? 'PROMPT' : 'BROWSER'));
         self::setLog(date('d') . '/' . Player_Utils::getMonth(date('m'), array('UPP', 'CUT')) . '/' . date('Y') . ' - ' . date('h:i:s'));
         self::setLog(Player_Utils::getSeparator('=', 70));
         if (self::getDebug()) {
             echo self::getLog() . self::getBreakline();
         }
     }
     if (self::getDebug()) {
         echo $log . self::getBreakline();
     }
     self::setLog($log);
 }
コード例 #2
0
ファイル: Download.php プロジェクト: alexndreazevedo/iplayer
 public function run()
 {
     $path = Player_Flags::getFlag('path');
     $files = Player_Flags::getFlag('files');
     $this->setTimeOut();
     if (Player_Utils::getInterface()) {
         if ($this->getConfig()) {
             Player_Debug::setStatus('Downloading...');
             $this->clearUpdate($this->setConfig(), 'download settings');
             $this->clearUpdate($this->setPlaylist(), 'update playlists');
             $this->clearUpdate($this->setLoop(), 'update loops');
             $this->clearUpdate($this->setMedias(), 'download media');
             $this->clearUpdate($this->setLibrary(), 'download libraries');
             $this->clearUpdate($this->setPictures(), 'download images');
             $this->clearUpdate($this->setUpdate(), 'finish downloads');
             $this->clearUpdate($this->setDownload(), 'update log');
             Player_Debug::setStatus('Download finished.');
         }
     }
 }