请问一下各位高手下面第二个rss源怎么读取,第chul源我已经读取出来了但是不知道第二个rss源怎么读取出来 谢谢!
(1) http://money.163.com/special/00252EQ2/macrorss.xml
(2) http://news.baidu.com/n?cmd=1&class=civilnews&tn=rss
(1) http://money.163.com/special/00252EQ2/macrorss.xml
(2) http://news.baidu.com/n?cmd=1&class=civilnews&tn=rss
不就一个xml么?
//xml_parser_set_option -- 为指定 XML 解析进行选项设置
xml_parser_set_option($parser,XML_OPTION_SKIP_WHITE,1);
//xml_parse_into_struct -- 将 XML 数据解析到数组$values中
xml_parse_into_struct($parser,$buff,$values,$idx);
//xml_parser_free -- 释放指定的 XML 解析器
xml_parser_free($parser);
是不是编码问题?默认是utf-8的,但这个文档是g2312