我可以读取一个格式化文本的xml文件,然后用php将其写入数据库吗


Can I read an xml file that has formated text and then write it to database with php

Hye!我可以读取一个类似于的xml文件吗

<items>
<item>
<id_product>1</id_product>
<title>Product title</title>
<description><p>This is a<b>PRODUCT</b></p></description>
</item>
<item>
<id_product>2</id_product>
<title>Another Product title</title>
<description><p>This is the second <b>PRODUCT</b></br><a href="#">click here</a></p></description>
</item>
</itmes>

用php将其写入数据库?我的想法是,我还想用格式(锚、粗体、斜体、p等(

来写它

查看PHP的XML Parser 的PHP手册

您应该能够使用这些工具获取信息,然后将其写入数据库。