FRIHOSTFORUMSFAQTOSBLOGSDIRECTORY
You are invited to Log in or Register a Frihost Account!

MySQL Question

 


rameshbn1
Hi People,

Is there an easy way in PHP5 to write a new XML file to disk based on some dynamically generated data? I would also have to edit this file (add / remove entries) subsequently. I know SimpleXML should be able to do this but I can't figure it out - I'm just learning the ropes... Wink
tkGER
I think you should make a function which reads XML (whith simpleXML is OK), then change the data, and write the xml again.
Another technique which is very useful, is to make apache process xml files whith php.exe, and you can write code inside the xml file. like:
Code:
<title><? echo $_GET['title']; ?></title>
etc

Hope it helps
yjwong
You can use the PEAR modules too. The PEAR module PHP_Config has the ability to write an XML file based on a PHP array. It could also write to INI files and Apache-style configuration files.
Reply to topic    Frihost Forum Index -> Scripting -> Php and MySQL

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2007 Frihost, forums powered by phpBB.