|
PHP5中文手册
SimpleXMLElement->xpath()(PHP 5 >= 5.2.0) SimpleXMLElement->xpath() — Runs XPath query on XML data 说明SimpleXMLElement
array xpath
( string $path
)
The xpath method searches the SimpleXML node for children matching the XPath path . 参数
返回值Returns an array of SimpleXMLElement objects or FALSE in case of an error. 范例
Example#1 Xpath
<?php 上例将输出:
Notice that the two results are equal. |