How to modify xml file using PHP

前端 未结 3 845
被撕碎了的回忆
被撕碎了的回忆 2020-11-27 16:59

I want to modify my xml file in PHP based on the following criteria.

my xml structure look like this:



        
3条回答
  •  没有蜡笔的小新
    2020-11-27 17:34

    Document Object Model (DOM) is the answer.

    Load("file.xml");
     $root=$dom->documentElement;
     ...
     $dom->Save("file.xml");
    ?>
    

提交回复
热议问题