On 31.10.2005 10:16 Uhr, Marian Kostadinov wrote: > This is related to feature request 34839. > > [12 Oct 7:58pm CEST] stochnagara at hotmail dot com > > Description: > ------------ > The class SimpleXMLElement is wonderful and provides a great > functionality. > But I need to extend it and I don't have a way to determine whether a > given SimpleXMLElement is an attribute, an element, a CDATA section and > so on. > > So I suggest adding methods getName() and getType(). getName() returns > element's name for elements, attribute's name for attributes and so on. > getType() returns SimpleXMLElement::ELEMENT and so on.
SimpleXML is meant to be simple and the desicion was made to keep its API short. Use DOM if you want those more advanced features (there's dom_import_simplexml() and simplexml_import_dom() for easy and fast switching between those 2) chregu > > > > > Maybe it is late for 5.1.0 but 5.1.1 is a good place for this to appear. > -- christian stocker | Bitflux GmbH | schoeneggstrasse 5 | ch-8004 zurich phone +41 1 240 56 70 | mobile +41 76 561 88 60 | fax +41 1 240 56 71 http://www.bitflux.ch | [EMAIL PROTECTED] | GPG 0x5CE1DECB -- PHP Internals - PHP Runtime Development Mailing List To unsubscribe, visit: http://www.php.net/unsub.php