【发布时间】:2014-09-24 18:07:23
【问题描述】:
我有一个这样的对象:
SimpleXMLElement Object
(
[@attributes] => Array
(
[url] => http://openclipart.org/people/jgm104/Expression_of_Emotions.svg
[type] => image/svg+xml
[length] => 485314
)
)
如何从那里访问网址?
我试过$photos->item[$i]->enclosure->{"@attributes]"}
但它只显示空白的 SimpleXMLElement 对象。
【问题讨论】:
标签: php xml-parsing