This week I've been looking for functions to work with XML. If you want to create XML files, always use DOMXML functions (php compile --with-dom).
Here is some code: <? $doc = new_xmldoc ('1.0'); $root = $doc->add_root('sites'); $site = $root->new_child('site', ''); $site->new_child('title', 'PHP.net'); $site->new_child('url', 'http://www.php.net'); $site = $root->new_child('site', ''); $site->new_child('title', 'Test'); $site->new_child('url', 'http://localhost/teste.php'); $fp = @fopen('tst.xml', 'w'); if (!$fp) die('Error open tst.xml'); fwrite($fp, $doc->dumpmem()); fclose($fp); echo $doc->dumpmem(); ?> _______________________________________________________________________________________________ Yahoo! GeoCities Tenha seu lugar na Web. Construa hoje mesmo sua home page no Yahoo! GeoCities. É fácil e grátis! http://br.geocities.yahoo.com/ -- PHP General Mailing List (http://www.php.net/) To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] To contact the list administrators, e-mail: [EMAIL PROTECTED]