You are here

protected function FeedsXPathParserHTML::getRaw in Feeds XPath Parser 6

Same name and namespace in other branches
  1. 7 FeedsXPathParserHTML.inc \FeedsXPathParserHTML::getRaw()

Overrides FeedsXPathParserBase::getRaw

File

./FeedsXPathParserHTML.inc, line 48
s Provides the FeedsXPathParserHTML class.

Class

FeedsXPathParserHTML
Parse HTML using XPath.

Code

protected function getRaw(DOMNode $node) {

  // DOMDocument::saveHTML() cannot take $node as an argument prior to 5.3.6.
  if (version_compare(phpversion(), '5.3.6', '>=')) {
    return $this->doc
      ->saveHTML($node);
  }
  return $this->doc
    ->saveXML($node);
}