summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Stocker <chregu@php.net>2002-03-13 08:15:54 +0000
committerChristian Stocker <chregu@php.net>2002-03-13 08:15:54 +0000
commit20120ecff34b34400563116bf7e6c1b35959fe4d (patch)
treecf8cbd24f9b6a9d202c333708e28373626f7cf10
parent53b34e0e349eddf9b5058800e1b45c086ca8141f (diff)
downloadphp-git-20120ecff34b34400563116bf7e6c1b35959fe4d.tar.gz
Return attribute name in node_name(), if it's a XML_ATTRIBUTE_NODE
-rw-r--r--ext/domxml/php_domxml.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/domxml/php_domxml.c b/ext/domxml/php_domxml.c
index 78fe2bc558..b2d7765d90 100644
--- a/ext/domxml/php_domxml.c
+++ b/ext/domxml/php_domxml.c
@@ -1439,6 +1439,10 @@ PHP_FUNCTION(domxml_node_name)
str = "#text";
break;
+ case XML_ATTRIBUTE_NODE:
+ str = n->name;
+ break;
+
case XML_CDATA_SECTION_NODE:
str = "#cdata-section";
break;