Goose\Tests\Harness\TestTrait::html PHP Méthode

html() public méthode

public html ( DOMWrap\Document | DOMWrap\Element | Goose\Article $doc ) : string
$doc DOMWrap\Document | DOMWrap\Element | Goose\Article
Résultat string
    public function html($doc)
    {
        if ($doc instanceof Document) {
            $el = $doc->documentElement;
        } else {
            if ($doc instanceof Element) {
                $el = $doc;
                $doc = $doc->ownerDocument;
            } else {
                if ($doc instanceof Article) {
                    $doc = $doc->getDoc();
                    $el = $doc->documentElement;
                }
            }
        }
        return $doc->saveXML($el);
    }