Copied!

Node wrapper - tries to wrap a set of XML/DOM-nodes in a surrounding document based on the passed validator markup parser

CloneableInstantiable
Methods
public wrap( $parser, $nodes, $charset = NULL)
 

Attempts to wrap a document in a surrounding document

  • param string $parser Parser name (HtmlValidator\Validator::PARSER_*)
  • param string $nodes Nodes to wrap
  • param string $charset Charset to use
  • throws \Exception\UnknownParserException If the given parser is not known
  • return string
Methods
protected wrapInHtml4Document( $nodes, $charset = NULL, $parser = NULL)
 

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
protected wrapInHtml5Document( $nodes, $charset = NULL)
 

Wraps a set of HTML nodes in an HTML5-document

  • param string $nodes One or more HTML-nodes, as a string
  • param string $charset Charset to specify in meta tag
  • return string
protected wrapInXmlDocument( $nodes, $charset = NULL)
 

Wraps a set of XML nodes in an XML-document

  • param string $nodes One or more XML-nodes, as a string
  • param string $charset Charset to specify in XML-document
  • return string
© 2024 Bruce Wells
Search Namespaces \ Classes
Configuration