Print xml with php

后端 未结 4 1200
北荒
北荒 2020-12-22 08:53

I have this php code

    \\n\";
    echo \"\\n\";
    echo \"\\t<         


        
4条回答
  •  悲哀的现实
    2020-12-22 09:26

    You have to use proper content-type, as the others have said. I recommend you to use XMLReader. Or if you want a n easier way, then try to use Heredoc string syntax with sprintf and htmlspecialchars to encode values with characters that have special meanings in XML (like <>&)

提交回复
热议问题