protected function wrapInHtml4Document($nodes, $charset = null, $parser = null) {
        if ($parser === Validator::PARSER_HTML4TR) {
            $doctype = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">';
        } else {
            $doctype = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">';
        }

        $charset = strtolower($charset ?: Validator::CHARSET_UTF_8);

        $document  = $doctype . PHP_EOL;
        $document .= '<html><head>' . PHP_EOL;
        $document .= '<meta http-equiv="Content-Type" content="text/html; charset=' . $charset . '">' . PHP_EOL;
        $document .= '<title>Validation document</title>' . PHP_EOL;
        $document .= '</head><body>' . $nodes . '</body></html>';

        return $document;
    }
protected function wrapInHtml4Document($nodes, $charset = null, $parser = null) {
        if ($parser === Validator::PARSER_HTML4TR) {
            $doctype = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">';
        } else {
            $doctype = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">';
        }

        $charset = strtolower($charset ?: Validator::CHARSET_UTF_8);

        $document  = $doctype . PHP_EOL;
        $document .= '<html><head>' . PHP_EOL;
        $document .= '<meta http-equiv="Content-Type" content="text/html; charset=' . $charset . '">' . PHP_EOL;
        $document .= '<title>Validation document</title>' . PHP_EOL;
        $document .= '</head><body>' . $nodes . '</body></html>';

        return $document;
    }
protected function wrapInHtml4Document ( $ nodes , $ charset = null , $ parser = null ) { if ( $ parser === Validator :: PARSER_HTML4TR ) { $ doctype = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">' ; } else { $ doctype = '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">' ; } $ charset = strtolower ( $ charset ? : Validator :: CHARSET_UTF_8 ) ; $ document = $ doctype . PHP_EOL ; $ document .= '<html><head>' . PHP_EOL ; $ document .= '<meta http-equiv="Content-Type" content="text/html; charset=' . $ charset . '">' . PHP_EOL ; $ document .= '<title>Validation document</title>' . PHP_EOL ; $ document .= '</head><body>' . $ nodes . '</body></html>' ; return $ document ; }
Wraps a set of HTML nodes in an HTML4-document

@param  string $nodes   One or more HTML-nodes, as a string
@param  string $charset Charset to specify in meta tag
@param  string $parser  Validator parser used
@return string
Wraps a set of HTML nodes in an HTML4 - document