[TYPO3-core] RFC: Bug #9217: typo3ajax::renderAsXML does not always render XML
Francois Suter
fsuter at cobweb.ch
Sat Aug 23 18:11:04 CEST 2008
Hi Steffen,
> Example:
> $xml = XMLReader::open($this->content);
> $xml->setParserProperty(XMLReader::VALIDATE, true);
> if ($xml->isValid()) {...}
The above code is wrong. I searched a bit and came up with the following
test code:
$xml = '<test><value>dummy</value></test>';
$reader = new XMLReader();
$reader->XML($xml);
if ($reader->isValid()) {
echo 'OK';
}
else {
echo 'KO';
}
but it sternly refuses to validate my XML. Adding the XML prologue:
$xml = '<?xml version="1.0"
encoding="UTF-8"?><test><value>dummy</value></test>';
doesn't help either, so I'm not sure your solution is such a good idea.
Do you actually have a working example?
Cheers
--
Francois Suter
Cobweb Development Sarl - http://www.cobweb.ch
More information about the TYPO3-team-core
mailing list