-1
私は早急に次のXMLファイルを読み取る方法を知っておく必要があります。PHPの複雑なXMLファイルからさまざまな値を抽出する方法は?
<uclassify xmlns="http://api.uclassify.com/1/ResponseSchema" version="1.00">
<status success="true" statusCode="2000"/>
<readCalls>
<classify id="cls1">
<classification>
<class className="negative" p="0.741735"/>
<class className="positive" p="0.258265"/>
</classification>
</classify>
</readCalls>
</uclassify>
私は次のことを知っておく必要があります。
$status_code = ... (should be 2000)
$negative = ... (the value of p, should be 0.741735)
$positive = ... (the value of p, should be 0.258265)
敬具
アンドレ
何を試しましたか? PHPの場合でも、XMLを解析するための十分な先例があります。 – deceze
[PHPでXMLファイルから情報を外挿する方法]の複製が可能です(http://stackoverflow.com/questions/1183657/how-to-extrapolate-information-from-xml-file-in-php) – deceze
['SimpleXML '](http://php.net/manual/en/book.simplexml.php)、それは[XPath](http://www.php.net/manual/en/simplexmlelement.xpath.php)エンジンが簡単に使えるあなたが望むことをやりなさい。 – DaveRandom