#21172 [Opn->Fbk]: PHP crashed when try to access XML DOM COM interfaces
| From: | iliaa@php.net | Date: | Tue, 24 Dec 2002 23:52:55 +0000 |
| Subject: | #21172 [Opn->Fbk]: PHP crashed when try to access XML DOM COM interfaces | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-28337@lists.php.net to get a copy of this message | ||
ID: 21172
Updated by: iliaa@php.net
Reported By: vodmal@newmail.ru
-Status: Open
+Status: Feedback
Bug Type: COM related
Operating System: Windows 2000
PHP Version: 4.2.1
New Comment:
Please try using this CVS snapshot:
http://snaps.php.net/php4-latest.tar.gz
For Windows:
http://snaps.php.net/win32/php4-win32-latest.zip
Previous Comments:
------------------------------------------------------------------------
[2002-12-24 07:55:40] vodmal@newmail.ru
test.xml:
<?xml version="1.0"?>
<test a="g" b="false">
<v val="1">aa</v>
<v val="2">bb</v>
<v val="3">nn</v>
</test>
test.php:
<?
$MSXML = new COM("Msxml2.DOMDocument");
if ($MSXML->load("D:\\Inetpub\\wwwroot\\vphpmail\\test.xml"))
{
$nodeList = $MSXML->getElementsByTagName("v");
for ($i=0;$i<$nodeList->length;$i++)
{
$node = $nodeList->nextNode();
$attribs = $node->attributes;
$attr = $attribs->getNamedItem("val");
echo($attr->Name."<BR>"); // This is crash
echo($node->nodeName." ".$node->xml."<BR>");
}
}
else
{
echo("BAD<br>");
echo(
"Error in file <b>".$MSXML->parseError->url."</B> at line
<b>".
$MSXML->parseError->line."</b> in pos
<b>".$MSXML->parseError->linepos."</b>");
}
?>
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/?id=21172&edit=1