Esempio n. 1
0
 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);
 }
Esempio n. 2
0
 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.');
         }
     }
 }