skalie
the honourable
Registered: Sep 2001
Location: ........
Posts: 14954 |
Here's the code that worked for me, for what it's worth (php)
code:
$xml = xml_parser_create();
$rss = new pc_RSS_parser_newspage;
xml_set_object($xml, $rss);
xml_set_element_handler($xml, 'start_element', 'end_element');
xml_set_character_data_handler($xml, 'character_data');
xml_parser_set_option($xml, XML_OPTION_CASE_FOLDING, false);
$feed = 'http://feeds.feedburner.com/medicalfacts'; // this one you'll probably want to change
$fp = fopen($feed, 'r') or die("Not getting the rss feed");
while($data = fread($fp, 4096)){ //4096
xml_parse($xml, $data, feof($fp)) or die("Parse ain't working today, sir");
}
fclose($fp);
xml_parser_free($xml);
Report this post to a moderator |
IP: Logged
|