Suppression noeud XML en PHP
Résolu/Fermé
Apaachee
Messages postés
248
Date d'inscription
mardi 13 novembre 2007
Statut
Membre
Dernière intervention
25 août 2011
-
27 mai 2009 à 19:25
Apaachee Messages postés 248 Date d'inscription mardi 13 novembre 2007 Statut Membre Dernière intervention 25 août 2011 - 27 mai 2009 à 19:47
Apaachee Messages postés 248 Date d'inscription mardi 13 novembre 2007 Statut Membre Dernière intervention 25 août 2011 - 27 mai 2009 à 19:47
A voir également:
- Suppression noeud XML en PHP
- Forcer suppression fichier - Guide
- Xml download - Télécharger - Édition & Programmation
- Easy php - Télécharger - Divers Web & Internet
- Suppression page word - Guide
- Office xml handler - Télécharger - Traitement de texte
1 réponse
Apaachee
Messages postés
248
Date d'inscription
mardi 13 novembre 2007
Statut
Membre
Dernière intervention
25 août 2011
47
27 mai 2009 à 19:47
27 mai 2009 à 19:47
$collection = simplexml_load_file("../Information/Collection/".$login.".xml "); $i=0; $a = -1; foreach($collection->children() as $bd){ if($collection->BD[$i]->titre == $_GET["titre"] && $collection->BD[$i]->annee == $_GET["annee"]) $a = $i; $i++; } if($a >= -1){ unset($collection->BD[$a]); $collection->asXML("../Information/Collection/".$login.".xml "); }
Oublié de faire un asXML à la fin !!