(PHP 5, PHP 7, PHP 8)
Introducción
DOMAttr representa un atributo en el objeto
DOMElement.
Propiedades
- name
-
El nombre del atributo.
- ownerElement
-
El elemento que contiene el atributo o null
.
- schemaTypeInfo
-
Aún no implementado, siempre es null
- specified
-
Aún no implementado, siempre es true
.
- value
-
El valor del atributo.
Nota:
Note, XML entities are expanded upon setting a value.
Thus the &
character has a special meaning.
Setting value to itself will fail when value contains an &
.
To avoid entity expansion, use DOMElement::setAttribute() instead.
Tabla de contenidos
greubel at nkey dot de ¶9 years ago
Please take care on debugging DOMAttr related code. This will cause an E_WARNING that retrieving schemaTypeInfo attribute is not implemented yet. An IDE like Eclipse will inspect the object and its member elements. In conjunction with registered error handlers, which will translate the E_WARNING into Exception your debugging session will end unexpectedly. This has caused me some trouble while debugging my PHPUnit test case in eclipse using "Makegood" plugin.
A possible workarround is to deactivate the error handling during debugging using error_reporting(0). Remove the statement after finishing your debugging session.
Notable ticket in Bugtracker: https://bugs.php.net/bug.php?id=61858
And a xdebug tracker ticket: http://bugs.xdebug.org/view.php?id=910