/** * Creates new document from markup. * Chainable. * * @param unknown_type $markup * @return pQueryObject|QueryTemplatesSource|QueryTemplatesParse|QueryTemplatesSourceQuery */ public static function newDocumentPHP($markup = null, $contentType = "text/html") { // TODO pass charset to phpToMarkup if possible (use DOMDocumentWrapper function) $markup = pQuery::phpToMarkup($markup, self::$defaultCharset); return self::newDocument($markup, $contentType); }