libxml_use_internal_errors()

It  disable libxml errors and allow user to fetch error information as needed

Example

<?php
libxml_use_internal_errors()
?>