Zend Framework  3.0
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
HtmlTag Class Reference

Renders <html> tag (both opening and closing) of a web page, to which some custom attributes can be added dynamically. More...

Public Member Functions

 __invoke (array $attribs=[])
 Retrieve object instance; optionally add attributes.
 
 setAttribute ($attrName, $attrValue)
 Set new attribute.
 
 setAttributes (array $attribs)
 Add new or overwrite the existing attributes.
 
 getAttributes ()
 
 setUseNamespaces ($useNamespaces)
 
 getUseNamespaces ()
 
 openTag ()
 Render opening tag.
 
 closeTag ()
 Render closing tag.
 
- Public Member Functions inherited from AbstractHtmlElement
 getClosingBracket ()
 Get the tag closing bracket.
 
- Public Member Functions inherited from AbstractHelper
 setView (Renderer $view)
 Set the View object.
 
 getView ()
 Get the view object.
 

Protected Member Functions

 handleNamespaceAttributes ()
 
- Protected Member Functions inherited from AbstractHtmlElement
 isXhtml ()
 Is doctype XHTML?
 
 htmlAttribs ($attribs)
 Converts an associative array to a string of tag attributes.
 
 normalizeId ($value)
 Normalize an ID.
 

Protected Attributes

 $attributes = []
 
 $useNamespaces = false
 
- Protected Attributes inherited from AbstractHtmlElement
 $closingBracket = null
 
- Protected Attributes inherited from AbstractHelper
 $view = null
 

Additional Inherited Members

- Public Attributes inherited from AbstractHtmlElement
const EOL = PHP_EOL
 EOL character.
 

Detailed Description

Renders <html> tag (both opening and closing) of a web page, to which some custom attributes can be added dynamically.

Author
Nikola Posa posa..nosp@m.niko.nosp@m.la@gm.nosp@m.ail..nosp@m.com

Member Function Documentation

__invoke ( array  $attribs = [])

Retrieve object instance; optionally add attributes.

Parameters
array$attribs
Returns
self
closeTag ( )

Render closing tag.

Returns
string
getAttributes ( )
Returns
array
getUseNamespaces ( )
Returns
bool
handleNamespaceAttributes ( )
protected
openTag ( )

Render opening tag.

Returns
string
setAttribute (   $attrName,
  $attrValue 
)

Set new attribute.

Parameters
string$attrName
string$attrValue
Returns
self
setAttributes ( array  $attribs)

Add new or overwrite the existing attributes.

Parameters
array$attribs
Returns
self
setUseNamespaces (   $useNamespaces)
Parameters
bool$useNamespaces
Returns
self

Member Data Documentation

$attributes = []
protected
$useNamespaces = false
protected