1
0
mirror of https://github.com/php/doc-en.git synced 2026-03-23 23:32:18 +01:00
Files
archived-doc-en/reference/dom/constants.xml
2025-01-14 12:29:20 +00:00

485 lines
15 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<!-- $Revision$ -->
<chapter xml:id="dom.constants" xmlns="http://docbook.org/ns/docbook">
&reftitle.constants;
&extension.constants;
<table>
<title>XML constants</title>
<tgroup cols="3">
<thead>
<row>
<entry>&Constants;</entry>
<entry>Value</entry>
<entry>&Description;</entry>
</row>
</thead>
<tbody>
<row xml:id="constant.xml-element-node">
<entry>
<constant>XML_ELEMENT_NODE</constant>
(<type>int</type>)
</entry>
<entry>1</entry>
<entry>Node is a <classname>DOMElement</classname> / <classname>Dom\Element</classname></entry>
</row>
<row xml:id="constant.xml-attribute-node">
<entry>
<constant>XML_ATTRIBUTE_NODE</constant>
(<type>int</type>)
</entry>
<entry>2</entry>
<entry>Node is a <classname>DOMAttr</classname> / <classname>Dom\Attr</classname></entry>
</row>
<row xml:id="constant.xml-text-node">
<entry>
<constant>XML_TEXT_NODE</constant>
(<type>int</type>)
</entry>
<entry>3</entry>
<entry>Node is a <classname>DOMText</classname> / <classname>Dom\Text</classname></entry>
</row>
<row xml:id="constant.xml-cdata-section-node">
<entry>
<constant>XML_CDATA_SECTION_NODE</constant>
(<type>int</type>)
</entry>
<entry>4</entry>
<entry>Node is a <classname>DOMCharacterData</classname> / <classname>Dom\CharacterData</classname></entry>
</row>
<row xml:id="constant.xml-entity-ref-node">
<entry>
<constant>XML_ENTITY_REF_NODE</constant>
(<type>int</type>)
</entry>
<entry>5</entry>
<entry>Node is a <classname>DOMEntityReference</classname> / <classname>Dom\EntityReference</classname></entry>
</row>
<row xml:id="constant.xml-entity-node">
<entry>
<constant>XML_ENTITY_NODE</constant>
(<type>int</type>)
</entry>
<entry>6</entry>
<entry>Node is a <classname>DOMEntity</classname> / <classname>Dom\Entity</classname></entry>
</row>
<row xml:id="constant.xml-pi-node">
<entry>
<constant>XML_PI_NODE</constant>
(<type>int</type>)
</entry>
<entry>7</entry>
<entry>Node is a <classname>DOMProcessingInstruction</classname> / <classname>Dom\ProcessingInstruction</classname></entry>
</row>
<row xml:id="constant.xml-comment-node">
<entry>
<constant>XML_COMMENT_NODE</constant>
(<type>int</type>)
</entry>
<entry>8</entry>
<entry>Node is a <classname>DOMComment</classname> / <classname>Dom\Comment</classname></entry>
</row>
<row xml:id="constant.xml-document-node">
<entry>
<constant>XML_DOCUMENT_NODE</constant>
(<type>int</type>)
</entry>
<entry>9</entry>
<entry>Node is a <classname>DOMDocument</classname> / <classname>Dom\Document</classname></entry>
</row>
<row xml:id="constant.xml-document-type-node">
<entry>
<constant>XML_DOCUMENT_TYPE_NODE</constant>
(<type>int</type>)
</entry>
<entry>10</entry>
<entry>Node is a <classname>DOMDocumentType</classname> / <classname>Dom\DocumentType</classname></entry>
</row>
<row xml:id="constant.xml-document-frag-node">
<entry>
<constant>XML_DOCUMENT_FRAG_NODE</constant>
(<type>int</type>)
</entry>
<entry>11</entry>
<entry>Node is a <classname>DOMDocumentFragment</classname> / <classname>Dom\DocumentFragment</classname></entry>
</row>
<row xml:id="constant.xml-notation-node">
<entry>
<constant>XML_NOTATION_NODE</constant>
(<type>int</type>)
</entry>
<entry>12</entry>
<entry>Node is a <classname>DOMNotation</classname> / <classname>Dom\Notation</classname></entry>
</row>
<row xml:id="constant.xml-html-document-node">
<entry>
<constant>XML_HTML_DOCUMENT_NODE</constant>
(<type>int</type>)
</entry>
<entry>13</entry>
<entry/>
</row>
<row xml:id="constant.xml-dtd-node">
<entry>
<constant>XML_DTD_NODE</constant>
(<type>int</type>)
</entry>
<entry>14</entry>
<entry/>
</row>
<row xml:id="constant.xml-element-decl-node">
<entry>
<constant>XML_ELEMENT_DECL_NODE</constant>
(<type>int</type>)
</entry>
<entry>15</entry>
<entry/>
</row>
<row xml:id="constant.xml-attribute-decl-node">
<entry>
<constant>XML_ATTRIBUTE_DECL_NODE</constant>
(<type>int</type>)
</entry>
<entry>16</entry>
<entry/>
</row>
<row xml:id="constant.xml-entity-decl-node">
<entry>
<constant>XML_ENTITY_DECL_NODE</constant>
(<type>int</type>)
</entry>
<entry>17</entry>
<entry/>
</row>
<row xml:id="constant.xml-namespace-decl-node">
<entry>
<constant>XML_NAMESPACE_DECL_NODE</constant>
(<type>int</type>)
</entry>
<entry>18</entry>
<entry/>
</row>
<row xml:id="constant.xml-attribute-cdata">
<entry>
<constant>XML_ATTRIBUTE_CDATA</constant>
(<type>int</type>)
</entry>
<entry>1</entry>
<entry/>
</row>
<row xml:id="constant.xml-attribute-id">
<entry>
<constant>XML_ATTRIBUTE_ID</constant>
(<type>int</type>)
</entry>
<entry>2</entry>
<entry/>
</row>
<row xml:id="constant.xml-attribute-idref">
<entry>
<constant>XML_ATTRIBUTE_IDREF</constant>
(<type>int</type>)
</entry>
<entry>3</entry>
<entry/>
</row>
<row xml:id="constant.xml-attribute-idrefs">
<entry>
<constant>XML_ATTRIBUTE_IDREFS</constant>
(<type>int</type>)
</entry>
<entry>4</entry>
<entry/>
</row>
<row xml:id="constant.xml-attribute-entity">
<entry>
<constant>XML_ATTRIBUTE_ENTITY</constant>
(<type>int</type>)
</entry>
<entry>5</entry>
<entry/>
</row>
<row xml:id="constant.xml-attribute-nmtoken">
<entry>
<constant>XML_ATTRIBUTE_NMTOKEN</constant>
(<type>int</type>)
</entry>
<entry>7</entry>
<entry/>
</row>
<row xml:id="constant.xml-attribute-nmtokens">
<entry>
<constant>XML_ATTRIBUTE_NMTOKENS</constant>
(<type>int</type>)
</entry>
<entry>8</entry>
<entry/>
</row>
<row xml:id="constant.xml-attribute-enumeration">
<entry>
<constant>XML_ATTRIBUTE_ENUMERATION</constant>
(<type>int</type>)
</entry>
<entry>9</entry>
<entry/>
</row>
<row xml:id="constant.xml-attribute-notation">
<entry>
<constant>XML_ATTRIBUTE_NOTATION</constant>
(<type>int</type>)
</entry>
<entry>10</entry>
<entry/>
</row>
<row xml:id="constant.xml-local-namespace">
<entry>
<constant>XML_LOCAL_NAMESPACE</constant>
(<type>int</type>)
</entry>
<entry></entry>
<entry>A namespace declaration node.</entry>
</row>
</tbody>
</tgroup>
</table>
<table>
<title>HTML constants</title>
<tgroup cols="3">
<thead>
<row>
<entry>&Constants;</entry>
<entry>&Description;</entry>
</row>
</thead>
<tbody>
<row xml:id="constant.dom-html-no-default-ns">
<entry>
<constant>Dom\HTML_NO_DEFAULT_NS</constant>
(<type>int</type>)
</entry>
<entry>
<simpara>
This disables setting the namespace of elements during parsing when
using <classname>Dom\HTMLDocument</classname>.
This exists for backwards compatibility with
<classname>DOMDocument</classname>.
</simpara>
<caution>
<simpara>
Some DOM methods depend on the <acronym>HTML</acronym> namespace
being set.
By using this parser option, the behaviour of those methods can be
influenced.
</simpara>
</caution>
</entry>
</row>
</tbody>
</tgroup>
</table>
<table>
<title><classname>DOMException</classname> / <classname>Dom\Exception</classname> constants</title>
<tgroup cols="3">
<thead>
<row>
<entry>&Constants;</entry>
<entry>Value</entry>
<entry>&Description;</entry>
</row>
</thead>
<tbody>
<row xml:id="constant.dom-php-err">
<entry>
<constant>DOM_PHP_ERR</constant>
(<type>int</type>)
</entry>
<entry>0</entry>
<entry>
Error code not part of the DOM specification. Meant for PHP errors.
Deprecated as of PHP 8.4.0 because this is no longer used.
Prior to PHP 8.4.0, this was inconsistently used to indicate
out-of-memory situations.
</entry>
</row>
<row xml:id="constant.dom-index-size-err">
<entry>
<constant>DOM_INDEX_SIZE_ERR</constant> / <constant>Dom\INDEX_SIZE_ERR</constant>
(<type>int</type>)
</entry>
<entry>1</entry>
<entry>
If index or size is negative, or greater than the allowed value.
</entry>
</row>
<row xml:id="constant.domstring-size-err">
<entry>
<constant>DOMSTRING_SIZE_ERR</constant> / <constant>Dom\STRING_SIZE_ERR</constant>
(<type>int</type>)
</entry>
<entry>2</entry>
<entry>
If the specified range of text does not fit into a
<type>string</type>.
</entry>
</row>
<row xml:id="constant.dom-hierarchy-request-err">
<entry>
<constant>DOM_HIERARCHY_REQUEST_ERR</constant> / <constant>Dom\HIERARCHY_REQUEST_ERR</constant>
(<type>int</type>)
</entry>
<entry>3</entry>
<entry>If any node is inserted somewhere it doesn't belong</entry>
</row>
<row xml:id="constant.dom-wrong-document-err">
<entry>
<constant>DOM_WRONG_DOCUMENT_ERR</constant> / <constant>Dom\WRONG_DOCUMENT_ERR</constant>
(<type>int</type>)
</entry>
<entry>4</entry>
<entry>
If a node is used in a different document than the one that created it.
</entry>
</row>
<row xml:id="constant.dom-invalid-character-err">
<entry>
<constant>DOM_INVALID_CHARACTER_ERR</constant> / <constant>Dom\INVALID_CHARACTER_ERR</constant>
(<type>int</type>)
</entry>
<entry>5</entry>
<entry>
If an invalid or illegal character is specified, such as in a name.
</entry>
</row>
<row xml:id="constant.dom-no-data-allowed-err">
<entry>
<constant>DOM_NO_DATA_ALLOWED_ERR</constant> / <constant>Dom\NO_DATA_ALLOWED_ERR</constant>
(<type>int</type>)
</entry>
<entry>6</entry>
<entry>
If data is specified for a node which does not support data.
</entry>
</row>
<row xml:id="constant.dom-no-modification-allowed-err">
<entry>
<constant>DOM_NO_MODIFICATION_ALLOWED_ERR</constant> / <constant>Dom\NO_MODIFICATION_ALLOWED_ERR</constant>
(<type>int</type>)
</entry>
<entry>7</entry>
<entry>
If an attempt is made to modify an object where modifications are not allowed.
</entry>
</row>
<row xml:id="constant.dom-not-found-err">
<entry>
<constant>DOM_NOT_FOUND_ERR</constant> / <constant>Dom\NOT_FOUND_ERR</constant>
(<type>int</type>)
</entry>
<entry>8</entry>
<entry>
If an attempt is made to reference a node in a context where it does not exist.
</entry>
</row>
<row xml:id="constant.dom-not-supported-err">
<entry>
<constant>DOM_NOT_SUPPORTED_ERR</constant> / <constant>Dom\NOT_SUPPORTED_ERR</constant>
(<type>int</type>)
</entry>
<entry>9</entry>
<entry>
If the implementation does not support the requested type of object or operation.
</entry>
</row>
<row xml:id="constant.dom-inuse-attribute-err">
<entry>
<constant>DOM_INUSE_ATTRIBUTE_ERR</constant> / <constant>Dom\INUSE_ATTRIBUTE_ERR</constant>
(<type>int</type>)
</entry>
<entry>10</entry>
<entry>
If an attempt is made to add an attribute that is already in use elsewhere.
</entry>
</row>
<row xml:id="constant.dom-invalid-state-err">
<entry>
<constant>DOM_INVALID_STATE_ERR</constant> / <constant>Dom\INVALID_STATE_ERR</constant>
(<type>int</type>)
</entry>
<entry>11</entry>
<entry>
If an attempt is made to use an object that is not, or is no longer, usable.
</entry>
</row>
<row xml:id="constant.dom-syntax-err">
<entry>
<constant>DOM_SYNTAX_ERR</constant> / <constant>Dom\SYNTAX_ERR</constant>
(<type>int</type>)
</entry>
<entry>12</entry>
<entry>If an invalid or illegal string is specified.</entry>
</row>
<row xml:id="constant.dom-invalid-modification-err">
<entry>
<constant>DOM_INVALID_MODIFICATION_ERR</constant> / <constant>Dom\INVALID_MODIFICATION_ERR</constant>
(<type>int</type>)
</entry>
<entry>13</entry>
<entry>If an attempt is made to modify the type of the underlying object.</entry>
</row>
<row xml:id="constant.dom-namespace-err">
<entry>
<constant>DOM_NAMESPACE_ERR</constant> / <constant>Dom\NAMESPACE_ERR</constant>
(<type>int</type>)
</entry>
<entry>14</entry>
<entry>
If an attempt is made to create or change an object in a way which is
incorrect with regard to namespaces.
</entry>
</row>
<row xml:id="constant.dom-invalid-access-err">
<entry>
<constant>DOM_INVALID_ACCESS_ERR</constant> / <constant>Dom\INVALID_ACCESS_ERR</constant>
(<type>int</type>)
</entry>
<entry>15</entry>
<entry>
If a parameter or an operation is not supported by the underlying object.
</entry>
</row>
<row xml:id="constant.dom-validation-err">
<entry>
<constant>DOM_VALIDATION_ERR</constant> / <constant>Dom\VALIDATION_ERR</constant>
(<type>int</type>)
</entry>
<entry>16</entry>
<entry>
If a call to a method such as insertBefore or removeChild would make the Node
invalid with respect to "partial validity", this exception would be raised and
the operation would not be done.
</entry>
</row>
</tbody>
</tgroup>
</table>
</chapter>
<!-- Keep this comment at the end of the file
Local variables:
mode: sgml
sgml-omittag:t
sgml-shorttag:t
sgml-minimize-attributes:nil
sgml-always-quote-attributes:t
sgml-indent-step:1
sgml-indent-data:t
indent-tabs-mode:nil
sgml-parent-document:nil
sgml-default-dtd-file:"~/.phpdoc/manual.ced"
sgml-exposed-tags:nil
sgml-local-catalogs:nil
sgml-local-ecat-files:nil
End:
vim600: syn=xml fen fdm=syntax fdl=2 si
vim: et tw=78 syn=sgml
vi: ts=1 sw=1
-->