You are here

protected function XmlParser::startErrorHandling in Feeds extensible parsers 8

Starts internal error handling.

Subclasses can override this to being error handling.

Overrides ParserBase::startErrorHandling

1 call to XmlParser::startErrorHandling()
XmlParser::validateExpression in src/Feeds/Parser/XmlParser.php
Validates an expression.

File

src/Feeds/Parser/XmlParser.php, line 346

Class

XmlParser
Defines a XML parser using XPath.

Namespace

Drupal\feeds_ex\Feeds\Parser

Code

protected function startErrorHandling() {
  parent::startErrorHandling();
  libxml_clear_errors();
  $this->handleXmlErrors = libxml_use_internal_errors(TRUE);

  // Only available in PHP >= 5.2.11.
  // See http://symfony.com/blog/security-release-symfony-2-0-17-released for
  // details.
  if (function_exists('libxml_disable_entity_loader')) {
    $this->entityLoader = libxml_disable_entity_loader(TRUE);
  }
}