Пример #1
0
 /**
  *
  */
 protected function getURLContents()
 {
     if (isset($this->cache) && !$this->refresh) {
         $contents = $this->cache->load('URLContents', $loaded);
         if ($loaded) {
             return $contents;
         }
     }
     $contents = $this->request->init()->process();
     if ($contents === FALSE) {
         throw new Exception('URL konnte nicht gelesen werden: ' . Code::varInfo($this->request->getURL()));
     }
     if (isset($this->cache)) {
         $this->cache->store('URLContents', $contents);
     }
     return $contents;
 }