cvs: php4 /tests testdom

From: Date: Thu, 15 Jun 2000 07:06:38 +0000
Subject: cvs: php4 /tests testdom
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-284@lists.php.net to get a copy of this message
steinm Thu Jun 15 00:06:38 2000 EDT Modified files: /php4/tests testdom Log: - changes to handle the slightly different access to attributes Index: php4/tests/testdom diff -u php4/tests/testdom:1.16 php4/tests/testdom:1.17 --- php4/tests/testdom:1.16 Tue Mar 14 12:58:10 2000 +++ php4/tests/testdom Thu Jun 15 00:06:38 2000 @@ -7,9 +7,11 @@ echo " "; echo "<".$node->name; $attributes = $node->attributes(); - if(is_array($attributes)) - for(reset($attributes); $attrname = key($attributes); next($attributes)) - echo " ".$attrname."=".$node->getattr($attrname); + if(is_array($attributes)) { +//var_dump($attributes); + foreach($attributes as $attribute) + echo " ".$attribute->name."=".$node->getattr($attribute->name); + } echo ">\n"; $children = $node->children(); for($i=0; $i < count($children); $i++)

« previous php.cvs (#284) next »