DomNode->attributes

Returns list of attributes
()

array DomNode->attributes ( )

Code Examples / Notes » domnode_attributes

ian monroe

A function to get the value of an attribute given the name of the desired attribute and the results of attributes() to the second parameter.
<?php
function getAttribute($name, $att)
{
foreach($att as $i)
{
if($i->name()==$name)
return $i->value();
}
}?>