Love Fuel?    Donate

FuelPHP Forums

Ask your question about FuelPHP in the appropriate forum, or help others by answering their questions.
Error with Fuel package SimplePie
  • Hello, I get an error by using the Fuel package Simplepie. It says:
    ErrorException [ Error ]: Class 'Simplepie\SimplePie' not found
    PKGPATH/SIMPLEPIE/CLASSES/SIMPLEPIE/CORE.PHP @ LINE 2675

    I changed line 2675 to
    $this->data['items'] = static::merge_items($this->multifeed_objects, $start, $end, $this->item_limit);
    
    but then it said:
    ErrorException [ User Warning ]: Arguments must be SimplePie objects
    PKGPATH/SIMPLEPIE/CLASSES/SIMPLEPIE/CORE.PHP @ LINE 2793
  • I can't reproduce that here. I've got it running in an application, and it fetches the RSS feed just fine. I use this code:
    $feed = new \Simplepie\Factory();
    $feed->set_feed_url('http://datamapper.wanwizard.eu/rss.xml');
    $feed->set_cache_location('/tmp');
    $feed->init() and $this->view->set('news', $feed->get_items(), false);
    
  • Sorry,
    I forgot to say that I am using multiple feed urls with SimplePie. Line 2675 only gets executed if you use multiple URLs.
    if (!empty($this->multifeed_objects))
       {
        $this->data['items'] = SimplePie::merge_items($this->multifeed_objects, $start, $end, $this->item_limit);
       }
    
  • Ok, found and fixed.
  • Thank you :)

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion