How to encode data for showing xml in php?
I am generating XML开发者_开发百科 dynamically. There may be arbitrary data which is entered by users. Which characters do I have to encode in order to show them properly in the XML file?
I am using PHP.
htmlspecialchars($string, ENT_QUOTES);
精彩评论