10,000 BC Man Posted March 13, 2008 Share Posted March 13, 2008 Hello, My first post here. Great looking forum ! I am trying to install a simple RSS feed display function on this page. I installed the XML_Feed_Parser from the Pear packages using cPanel. Even though I follow the examples on the Pear site, I get this error: Fatal error: Class 'XML_Feed_Parser' not found in /home/djbarney/public_html/sdw/rss_test.php on line 7 Code ... source = 'http://sourceforge.net/export/rss2_projnews.php?group_id=191008'; try { $feed = new XML_Feed_Parser($source); } catch (XML_Feed_Parser_Exception $e) { die('Feed invalid: ' . $e->getMessage()); } It needs DOM. I checked that by looking at the PHP info ... it is installed as an extension. XML_Feed_Parser 1.0.2 PHP version 5.2.5 Linux, Apache. BC Man Link to comment https://forums.phpfreaks.com/topic/95994-php-cannot-find-xml_feed_parser-even-though-i-just-installed-it/ Share on other sites More sharing options...
BlueSkyIS Posted March 13, 2008 Share Posted March 13, 2008 did you restart apache after installing XML_Feed_Parser? Link to comment https://forums.phpfreaks.com/topic/95994-php-cannot-find-xml_feed_parser-even-though-i-just-installed-it/#findComment-491433 Share on other sites More sharing options...
10,000 BC Man Posted March 13, 2008 Author Share Posted March 13, 2008 did you restart apache after installing XML_Feed_Parser? No. I am not running the server. Shouldn't cPanel handle that ? Otherwise how can it install packages ? Thanks for the help . BC_Man Link to comment https://forums.phpfreaks.com/topic/95994-php-cannot-find-xml_feed_parser-even-though-i-just-installed-it/#findComment-491633 Share on other sites More sharing options...
BlueSkyIS Posted March 13, 2008 Share Posted March 13, 2008 how did you access Pear to install XML_Feed_Parser via cPanel? i would expect cPanel to restart itself after a cPanel-initiated installation, but if you're using command line Pear, there may be no way for cPanel to know about the installation, so it would have no reason to restart apache. another possibility: if you're not running the server (you're not root) but are a user on a virtual host on the server, installing XML_Feed_Parser may do nothing. if it's being installed locally but you're using the system (non-localized) PHP, it may not be installed. the results of your test script seem to indicate that it is not installed, at least not in the correct location. Link to comment https://forums.phpfreaks.com/topic/95994-php-cannot-find-xml_feed_parser-even-though-i-just-installed-it/#findComment-491641 Share on other sites More sharing options...
10,000 BC Man Posted March 13, 2008 Author Share Posted March 13, 2008 how did you access Pear to install XML_Feed_Parser via cPanel? Services / Software --> PHP Pear Packages cPanel lists it as installed. I think I'm going to talk to my host admin. BC Man Link to comment https://forums.phpfreaks.com/topic/95994-php-cannot-find-xml_feed_parser-even-though-i-just-installed-it/#findComment-491691 Share on other sites More sharing options...
10,000 BC Man Posted April 1, 2008 Author Share Posted April 1, 2008 SOLVED: I needed the line... require_once "XML/Feed/Parser.php"; BC_Man Link to comment https://forums.phpfreaks.com/topic/95994-php-cannot-find-xml_feed_parser-even-though-i-just-installed-it/#findComment-506440 Share on other sites More sharing options...
trq Posted April 1, 2008 Share Posted April 1, 2008 Just as a side note, the server does not need to be restarted after installing pear packages. You just need to make sure they are in your path and you include them. Link to comment https://forums.phpfreaks.com/topic/95994-php-cannot-find-xml_feed_parser-even-though-i-just-installed-it/#findComment-506443 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.