downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

DomNode->node_name> <DomNode->last_child
Last updated: Fri, 14 Aug 2009

view this page in

DomNode->next_sibling

(PHP 4 >= 4.1.0)

DomNode->next_sibling Retourne le prochain noeud frère

Description

domelement DomNode->next_sibling ( void )

DomNode->next_sibling retourne le prochain noeud frère du noeud courant. S'il n'y a pas de noeud fils suivant, cette fonction retournera FALSE (< PHP 4.3) ou NULL (>= 4.3). Vous pouvez utiliser cette fonction pour passer en revue tous les fils d'un noeud tel que présenté dans cet exemple.

Exemple #1 Listage des noeuds fils

<?php
include("exemple.inc");

if(!
$dom domxml_open_mem($xmlstr)) {
  echo 
"Erreur d'analyse du document\n";
  exit;
}

$elements $dom->get_elements_by_tagname("tbody");
$element $elements[0];
$child $element->first_child();

while(
$child) {
   
print_r($child);
   
$child $child->next_sibling();
}
?>

Voir aussi domnode_previous_sibling().



add a note add a note User Contributed Notes
DomNode->next_sibling
There are no user contributed notes for this page.

DomNode->node_name> <DomNode->last_child
Last updated: Fri, 14 Aug 2009
 
 
show source | credits | sitemap | contact | advertising | mirror sites