protected function MongoDBLogTestCase::asText in MongoDB 7
Same name and namespace in other branches
- 8 mongodb_watchdog/mongodb_watchdog.test \MongoDBLogTestCase::asText()
- 6 mongodb_watchdog/mongodb_watchdog.test \MongoDBLogTestCase::asText()
Extract the text contained by the element.
Parameters
\SimpleXMLElement $element: Element to extract text from.
Return value
string Extracted text.
1 call to MongoDBLogTestCase::asText()
- MongoDBLogTestCase::getLogEntries in mongodb_watchdog/
mongodb_watchdog.test - Get the log entry information form the page.
File
- mongodb_watchdog/
mongodb_watchdog.test, line 735 - Contains \MongoDBLogTestCase.
Class
Code
protected function asText(SimpleXMLElement $element) {
if (!is_object($element)) {
return $this
->fail('The element is not an element.');
}
return trim(html_entity_decode(strip_tags($element
->asXML())));
}