Php 打开远程gzip XML文件以与SimpleXML一起使用
检索和解压缩远程gzip XML文件时遇到问题 要获取我正在使用的文件,请执行以下操作:Php 打开远程gzip XML文件以与SimpleXML一起使用,php,xml,gzip,Php,Xml,Gzip,检索和解压缩远程gzip XML文件时遇到问题 要获取我正在使用的文件,请执行以下操作: $url = 'http://www.domain.com/xml.gzip'; $linkToXmlFile = fopen("compress.zlib://$url", "r"); 然后我试过: try { $xml = new SimpleXmlElement($rawFeed); ... } 没用。试过这个吗 $xml = new SimpleXMLElement("compr
$url = 'http://www.domain.com/xml.gzip';
$linkToXmlFile = fopen("compress.zlib://$url", "r");
然后我试过:
try {
$xml = new SimpleXmlElement($rawFeed);
...
}
没用。试过这个吗
$xml = new SimpleXMLElement("compress.zlib://$url", NULL, TRUE);
什么不起作用?您会遇到什么错误,它到底在哪里失败?可能重复的