PHP 4.0 Bug #8922: @xmldoc(...) doesn't quite suppress errors
| From: | colin at easydns dot com | Date: | Fri, 26 Jan 2001 01:20:46 +0000 |
| Subject: | PHP 4.0 Bug #8922: @xmldoc(...) doesn't quite suppress errors | ||
| Groups: | php.dev | ||
| Request: | Send a blank email to php-dev+get-45080@lists.php.net to get a copy of this message | ||
From: colin@easydns.com
Operating system: RH 7.0
PHP version: 4.0 Latest CVS (25/01/2001)
PHP Bug Type: DOM XML related
Bug description: @xmldoc(...) doesn't quite suppress errors
Take the following code:
<?php
$xml = '<?xml version="1.0"?><foo><bar></foo>';
$doc = @xmldoc($xml);
if (!$doc) {
echo "invalid xml\n";
}
?>
If you run it from the shell, the parser spits a bunch of messages out to STDOUT. It would be nice
if these could be repressed and/or captured easily by the script somehow (in $php_err_msg or
something).
- Colin
--
Edit Bug report at: http://bugs.php.net/?id=8922&edit=1