array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'es', ), 'this' => array ( 0 => 'domimplementation.createdocument.php', 1 => 'DOMImplementation::createDocument', ), 'up' => array ( 0 => 'class.domimplementation.php', 1 => 'DOMImplementation', ), 'prev' => array ( 0 => 'domimplementation.construct.php', 1 => 'DOMImplementation::__construct', ), 'next' => array ( 0 => 'domimplementation.createdocumenttype.php', 1 => 'DOMImplementation::createDocumentType', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'es', 'path' => 'reference/dom/domimplementation/createdocument.xml', ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); ?>
(PHP 5, PHP 7, PHP 8)
DOMImplementation::createDocument — Crea un objeto DOMDocument del tipo especificado con su elemento documento
$namespace
= null
, string $qualifiedName
= "", ?DOMDocumentType $doctype
= null
): DOMDocument|falseCrea un objeto DOMDocument del tipo especificado con su elemento documento.
namespace
La URI del espacio de nombres del elemento documento a crear.
qualifiedName
El nombre cualificado del elemento documento a crear.
doctype
El tipo de documento a crear o null
.
A new DOMDocument object or false
on error. If
namespace
, qualifiedName
,
and doctype
are null, the returned
DOMDocument is empty with no document element
DOM_WRONG_DOCUMENT_ERR
Lanzado si doctype
ya ha sido usado con un
documento diferente o fue creado desde una implementación diferente.
DOM_NAMESPACE_ERR
Lanzado si hay un error con el espacio de nombres, como determina
namespace
y qualifiedName
.
Versión | Descripción |
---|---|
8.0.3 |
namespace is now nullable.
|
8.0.0 |
doctype is now nullable.
|
8.0.0 |
Calling this function statically will
now throw an Error.
Previously, an E_DEPRECATED was raised.
|