note 79105 rejected from function.dom-domelement-setattribute by felipe

From: Date: Sun, 16 Dec 2007 10:20:47 +0000
Subject: note 79105 rejected from function.dom-domelement-setattribute by felipe
References: 1  Groups: php.notes 
Request: Send a blank email to php-notes+get-133628@lists.php.net to get a copy of this message
Note Submitter: andreas at gustafsson-green dot co dot uk ---- Example: $doc = new DOMDocument("1.0"); $node = $doc->createElement("para"); $newnode = $doc->appendChild($node); $rv = $newnode->setAttribute("align", "left"); if (!is_bool($rv)) { var_dump($rv); } Result: object(DOMAttr)#3 (0) { } So, the function does not return a boolean as the documentation indicates, instead it returns a DOMAttr object.

« previous php.notes (#133628) next »