domxml_set_attribute

(PHP 4 >= 4.0.5)

domxml_set_attribute -- 

Description

object domxml_set_attribute (resource node, string name, string value)

Uyarý

Bu modül DENEYSELDÝR. Bunun anlamý, burada listenen fonksiyonlar, fonksiyon isimleri, kýsaca burada yazýlan HER ÞEY PHP"nin ilerki sürümlerinde UYARI YAPILMAKSIZIN DEðÝÞTÝRÝLEBÝLÝR. Dikkatli olun, ve bu modülü aldýÐýnýz riski bilerek kullanýn.

Sets an attribute with name name of the given node on a value.

If we take the example from domxml_add_root() it is simple to add an attribute to the HEAD element by the simply calling the set_attribute() function of the node class.

Örnek 1. Adding an attribute to an element


<?php
$doc = new_xmldoc("1.0");
$root = $doc->add_root("HTML");
$head = $root->new_child("HEAD", "");
$head->new_child("TITLE", "Hier der Titel");
$head->set_attribute("Language", "ge");
echo $doc->dumpmem();
?>