emehrkay Posted June 6, 2007 Share Posted June 6, 2007 simple question from a man whose never used xml with php. i am created a doc with DomDocument - thats the easy part. what do i do to make it display as an xml doc? add a doctype? how do i do that? thanks Quote Link to comment https://forums.phpfreaks.com/topic/54484-how-do-i-display-a-dynamiclly-created-xml-doc/ Share on other sites More sharing options...
per1os Posted June 6, 2007 Share Posted June 6, 2007 www.php.net/header header("Content-Type: application/xml; charset=ISO-8859-1"); echo '<?xml version="1.0" encoding="iso-8859-1"?>' . "\n"; Add that to the top. Than print out the xml data. Quote Link to comment https://forums.phpfreaks.com/topic/54484-how-do-i-display-a-dynamiclly-created-xml-doc/#findComment-269487 Share on other sites More sharing options...
emehrkay Posted June 6, 2007 Author Share Posted June 6, 2007 gosh, i knew it was the header, but i was like nah thanks Quote Link to comment https://forums.phpfreaks.com/topic/54484-how-do-i-display-a-dynamiclly-created-xml-doc/#findComment-269499 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.