set_file() public method

Set an instance of {@see SimplePie_File} to use as a feed
public set_file ( &$file ) : boolean
return boolean True on success, false on failure
Exemplo n.º 1
0
 public function createSimplePieObject($fileName)
 {
     $filePath = self::calcFixtureFilePath($fileName);
     $feed = new SimplePie();
     $feed->set_file(new SimplePie_File($filePath));
     $feed->set_cache_location(sfConfig::get('sf_cache_dir'));
     if (!@$feed->init()) {
         return false;
     }
     return $feed;
 }
Exemplo n.º 2
0
 function test()
 {
     $feed = new SimplePie();
     $feed->set_file($this->data['file']);
     $feed->enable_cache(false);
     $feed->init();
     $this->result = $feed->get_link();
 }