--TEST-- XMLWriter: libxml2 XML Writer, write_attribute_ns function --CREDITS-- Mauricio Vieira #testfest PHPSP on 2014-07-05 --SKIPIF-- --FILE-- "\'&'); xmlwriter_write_element($xw, 'chars', "special characters: <>\"'&"); xmlwriter_end_element($xw); xmlwriter_end_document($xw); // Force to write and empty the buffer $output = xmlwriter_flush($xw, true); print $output; ?> --EXPECT-- special characters: <>"'&