ID: 30746 User updated by: manoj_smartsoft at rediffmail dot com Reported By: manoj_smartsoft at rediffmail dot com -Status: Open +Status: Bogus Bug Type: *XML functions Operating System: Windows-XP PHP Version: 5.0.2 New Comment:
To avoid this use the ascii values go to http://webdesign.about.com/library/bl_htmlcodes.htm Previous Comments: ------------------------------------------------------------------------ [2004-11-10 14:13:25] manoj_smartsoft at rediffmail dot com Description: ------------ If the XML file conatinx &,< or > in the data field, then the simplexml_load_file fails Reproduce code: --------------- // * bug_file.xml : START * // <?xml version='1.0' standalone='yes'?> <couples> <couple> <name>John&Marry</name> <age>John>Marry</age> </couple> </couples> // * bug_file.xml : END * // <?php $xml = simplexml_load_file("bug_file.xml"); echo $xml->couple[0]->name; // "So this language. It's ike..." ?> Expected result: ---------------- This should give me the following result John&Marry Actual result: -------------- The actual result is that, the function returns error. ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=30746&edit=1
