cvs: php-src /ext/dom php_dom.c
| From: | Rob Richards | Date: | Tue, 13 Jan 2004 14:13:34 +0000 |
| Subject: | cvs: php-src /ext/dom php_dom.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-25627@lists.php.net to get a copy of this message | ||
rrichards Tue Jan 13 09:13:34 2004 EDT
Modified files:
/php-src/ext/dom php_dom.c
Log:
fix getElementsByTagName and getElementsByTagNameNS - allow *
Index: php-src/ext/dom/php_dom.c
diff -u php-src/ext/dom/php_dom.c:1.47 php-src/ext/dom/php_dom.c:1.48
--- php-src/ext/dom/php_dom.c:1.47 Thu Jan 8 03:15:17 2004
+++ php-src/ext/dom/php_dom.c Tue Jan 13 09:13:21 2004
@@ -18,7 +18,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: php_dom.c,v 1.47 2004/01/08 08:15:17 andi Exp $ */
+/* $Id: php_dom.c,v 1.48 2004/01/13 14:13:21 rrichards Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -1085,8 +1085,8 @@
while (nodep != NULL && (*cur <= index || index == -1)) {
if (nodep->type == XML_ELEMENT_NODE) {
- if (xmlStrEqual(nodep->name, local)) {
- if (ns == NULL || (nodep->ns != NULL && xmlStrEqual(nodep->ns->href, ns))) {
+ if (xmlStrEqual(nodep->name, local) || xmlStrEqual("*", local)) {
+ if (ns == NULL || (nodep->ns != NULL && (xmlStrEqual(nodep->ns->href, ns) ||
xmlStrEqual("*", ns)))) {
if (*cur == index) {
ret = nodep;
break;