Class Element
HTML element node.
An element can have an arbitrary number of child nodes. Child nodes are either other elements, controls, plain text or values that are converted to strings when the element is rendered as HTML.
- Core\Object implements Core\Chainable
- Core\Set implements Core\Accessor
- Core\View\Driver\coreui\Element implements ArrayAccess, Countable
Direct known subclasses
Core\View\Driver\coreui\Element\A
,
Core\View\Driver\coreui\Element\COL
,
Core\View\Driver\coreui\Element\LEGEND
,
Core\View\Driver\coreui\Element\LI
,
Core\View\Driver\coreui\Element\LINK
,
Core\View\Driver\coreui\Element\META
,
Core\View\Driver\coreui\Element\OBJECT
,
Core\View\Driver\coreui\Element\OL
,
Core\View\Driver\coreui\Element\OPTGROUP
,
Core\View\Driver\coreui\Element\P
,
Core\View\Driver\coreui\Element\PARAM
,
Core\View\Driver\coreui\Element\SCRIPT
,
Core\View\Driver\coreui\Element\COLGROUP
,
Core\View\Driver\coreui\Element\SELECT
,
Core\View\Driver\coreui\Element\SOURCE
,
Core\View\Driver\coreui\Element\TABLE
,
Core\View\Driver\coreui\Element\TD
,
Core\View\Driver\coreui\Element\TEXTAREA
,
Core\View\Driver\coreui\Element\TH
,
Core\View\Driver\coreui\Element\TR
,
Core\View\Driver\coreui\Element\UL
,
Core\View\Driver\coreui\Element\VIDEO
,
Core\View\Driver\coreui\Element\DIV
,
Core\View\Driver\coreui\Element\FIELDSET
,
Core\View\Driver\coreui\Element\FORM
,
Core\View\Driver\coreui\Element\IFRAME
,
Core\View\Driver\coreui\Element\IMG
,
Core\View\Driver\coreui\Element\INPUT
,
Core\View\Driver\coreui\Element\LABEL
Indirect known subclasses
Core\View\Driver\coreui\Element\BUTTON
,
Core\View\Driver\coreui\Element\TBODY
,
Core\View\Driver\coreui\Element\TFOOT
,
Core\View\Driver\coreui\Element\THEAD
Package: CoreUI\Element
Since: 3.1
Requires: PHP 5.3
Version: 1.0
Located at View/Driver/coreui/Element.inc.php
Methods summary
public
|
|
protected
|
#
__construct(
Element constructor. |
public
string
|
|
public
|
|
public
|
|
public
|
#
append(
Appends a new element or control to the list of child nodes. |
public
|
|
public
|
|
public
integer
|
|
public static
static
|
|
public
|
#
extend(
Appends a new child node but returns an instance to this element instead. |
public
string
|
#
id( )
Returns an automatically assigned ID for the element. The ID is generated on first request and buffered by the element. An ID is unique per instance and automatically reset if an element is cloned. |
public
|
#
insertAt( integer $index,
Inserts a new child node at a specified position. The node previously occupying the specified position will be moved to the next position. |
public
boolean
|
|
public
boolean
|
|
public
boolean
|
|
public
|
|
public
boolean
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
mixed
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
|
|
public
mixed
|
|
public
|
|
public
|
|
public
|
Methods inherited from Core\Object
__autocreateFactory()
,
__call()
,
__processParameters()
,
attachMethod()
,
chain()
,
getValueForKey()
,
getValueForKeyPath()
,
getValueForUndefinedKey()
,
hash()
,
issetValueForKey()
,
setValueForKey()
,
setValueForKeyPath()
,
setValueForUndefinedKey()
,
uuid()
Constants summary
boolean |
AllowsInnerNL
If set, the rendering of the HTML tag represented by the element is not affected by newlines inside the tag. |
#
false
|
boolean |
AllowsOuterNL
If set, the rendering of the HTML tag represented by the element is not affected by newlines outside the tag. |
#
false
|
boolean |
AllowsShortTag
If set, the HTML tag represented by the element allows short tag notion. |
#
true
|
Constants inherited from Core\Object
AnyParameterType
,
AutochainParameterType
,
AutocreateParameterType
,
BooleanParameterType
,
CharParameterType
,
EnumParameterType
,
IntegerParameterType
,
RealParameterType
,
StringParameterType
,
UserParameterType
Properties summary
protected
|
$_v_attributes
Hash of element attributes. |
|
protected
mixed[]
|
$_v_children
Array of child nodes. |
|
protected
|
$_v_classes
Hash of assigned CSS classes. |
|
protected
|
$_v_proxy
CoreUI proxy driver instance. |
|
protected
|
$_v_styles
Hash of inline styles. |
|
protected
string
|
$_v_type
HTML tag name. |
|
protected
string
|
$_id
Buffered ID of element, automatically generated by the |
Magic properties
public read-only
|
$attributes
Associative array of HTML element attributes. |
public read-only
|
$classes
Hash of assigned CSS classes. |
public read-only
integer
|
$count
Number of child nodes. |
public read-only
string
|
$id
Unique ID of element instance. Automatically generated for each instance, cloned elements will also receive a new ID. |
public read-only
|
$proxy
CoreUI proxy driver instance. |
public read-only
|
$styles
Hash of inline styles. |
public read-only
string
|
$type
HTML tag name. |