Comunitatea PHP Romania
 

 
DOMNode->appendChild

DOMNode->appendChild

(no version information, might be only in CVS)

DOMNode->appendChild --  Adds new child at the end of the children

Description

object DOMNode->appendChild ( object newnode)

This functions appends a child to an existing list of children or creates a new list of children. The child can be created with e.g. DOMDocument->createElement(), DOMDocument->createTextNode() etc. or simply by using any other node.

Throws DOMException if node cannot be appended.

The following example will add a new element node to a fresh document.

Exemplu 1. Adding a child

<?php
$doc
= new DOMDocument();
$node = $doc->createElement("para");
$newnode = $doc->appendChild($node);
print
$doc->saveXML();
?>

Ultimele discutii in forum RSS Forum

Ultimele articole Ultimele articole

Top membri

Pirahna Pirahna
la birou
carco carco
Bucuresti
Birkoff Birkoff
Bucuresti
Mascka Mascka
Braila
raul_ raul_
whooper whooper
Toronto ON
mihaitha mihaitha
Sibiu
gabysolomon gabysolomon
Bacau
oriceon oriceon
Constanta
garlicinicolae garlicinicolae

Newsletter


Email:
 inscriere
 renuntare
 
 Arhiva newsletter

Parteneriat

Copyright © 2001-2008 PHP Romania Add PHPRomania to Google Add PHPRomania to Del.icio.us Add PHPRomania to Stumbleupon Add PHPRomania to Yahoo! Add PHPRomania to Digg Add PHPRomania to Blink Soul Calibur III Mp3 | Free Advertising | Skateboarding | RC Helicopters | Loans
Ads: Partener Way2Web Nework: gazduire web | inregistrare domenii | web design | imobiliare | web hosting
Powered by Simplis