Class HtmlHelper
Html Helper class for easy use of HTML widgets.
HtmlHelper encloses all methods needed while working with HTML pages.
Link: http://book.cakephp.org/2.0/en/core-libraries/helpers/html.html
Copyright: Copyright 2005-2011, Cake Software Foundation, Inc. (http://cakefoundation.org)
License: License (http://www.opensource.org/licenses/mit-license.php)
Location: Cake/View/Helper/HtmlHelper.php
Properties summary
-
$_attributeFormat
protectedstring
Format to attribute -
$_crumbs
protectedarray
Breadcrumbs. -
$_docTypes
protectedarray
Document type definitions -
$_includedScripts
protectedarray
Names of script files that have been included once -
$_minimizedAttributeFormat
protectedstring
Format to attribute -
$_minimizedAttributes
protectedarray
Minimized attributes -
$_scriptBlockOptions
protectedarray
Options for the currently opened script block buffer if any. -
$_tags
protectedarray
html tags used by this helper.
Inherited Properties
Method Summary
-
__construct() public
Constructor -
_nestedListItem() protected
Internal function to build a nested list (UL/OL) out of an associative array. -
addCrumb() public
Adds a link to the breadcrumbs array. -
charset() public
Returns a charset META-tag. -
css() public
Creates a link element for CSS stylesheets. -
div() public
Returns a formatted DIV tag for HTML FORMs. -
docType() public
Returns a doctype string. -
getCrumbList() public
Returns breadcrumbs as a (x)html list -
getCrumbs() public
Returns the breadcrumb trail as a sequence of »-separated links. -
image() public
Creates a formatted IMG element. If
$options['url']
is provided, an image link will be generated with the link pointed at$options['url']
. This method will set an empty alt attribute if one is not supplied. -
link() public
Creates an HTML link. -
loadConfig() public
Load Html tag configuration. -
meta() public
Creates a link to an external resource and handles basic meta tags -
nestedList() public
Build a nested list (UL/OL) out of an associative array. -
para() public
Returns a formatted P tag. -
script() public
Returns one or many<script>
tags depending on the number of scripts given. -
scriptBlock() public
Wrap $script in a script tag. -
scriptEnd() public
End a Buffered section of Javascript capturing. Generates a script tag inline or in
$scripts_for_layout
depending on the settings used when the scriptBlock was started -
scriptStart() public
Begin a script block that captures output until HtmlHelper::scriptEnd() is called. This capturing block will capture all output between the methods and create a scriptBlock from it.
-
style() public
Builds CSS style data from an array of CSS properties -
tableCells() public
Returns a formatted string of table rows (TR's with TD's in them). -
tableHeaders() public
Returns a row of formatted and named TABLE headers. -
tag() public
Returns a formatted block tag, i.e DIV, SPAN, P. -
useTag() public
Returns a formatted existent block of $tags
Method Detail
__construct() public ¶
__construct( View
$View , array $settings = array() )
Constructor
Settings
configFile
A file containing an array of tags you wish to redefine.
Customizing tag sets
Using the configFile
option you can redefine the tag HtmlHelper will use.
The file named should be compatible with HtmlHelper::loadConfig().
Parameters
-
View
$View - The View this helper is being attached to.
- array $settings optional array()
- Configuration settings for the helper.
Overrides
_nestedListItem() protected ¶
_nestedListItem( array $items , array $options , array $itemOptions , string $tag )
Internal function to build a nested list (UL/OL) out of an associative array.
Parameters
- array $items
- Set of elements to list
- array $options
- Additional HTML attributes of the list (ol/ul) tag
- array $itemOptions
- Additional HTML attributes of the list item (LI) tag
- string $tag
- Type of list tag to use (ol/ul)
Returns
The nested list element
See
addCrumb() public ¶
addCrumb( string $name , string $link = null , mixed $options = null )
Adds a link to the breadcrumbs array.
Parameters
- string $name
- Text for link
- string $link optional null
- URL for link (if empty it won't be a link)
- mixed $options optional null
- Link attributes e.g. array('id' => 'selected')
See
Link
charset() public ¶
charset( string $charset = null )
Returns a charset META-tag.
Parameters
- string $charset optional null
The character set to be used in the meta tag. If empty, The App.encoding value will be used. Example: "utf-8".
Returns
A meta tag containing the specified character set.
Link
css() public ¶
css( mixed $path , string $rel = null , array $options = array() )
Creates a link element for CSS stylesheets.
Usage
Include one CSS file:
echo $this->Html->css('styles.css');
Include multiple CSS files:
echo $this->Html->css(array('one.css', 'two.css'));
Add the stylesheet to the $scripts_for_layout
layout var:
$this->Html->css('styles.css', null, array('inline' => false));
Options
inline
If set to false, the generated tag appears in the head tag of the layout. Defaults to true
Parameters
- mixed $path
The name of a CSS style sheet or an array containing names of CSS stylesheets. If
$path
is prefixed with '/', the path will be relative to the webroot of your application. Otherwise, the path will be relative to your CSS path, usually webroot/css.- string $rel optional null
- Rel attribute. Defaults to "stylesheet". If equal to 'import' the stylesheet will be imported.
- array $options optional array()
- Array of HTML attributes.
Returns
CSS or tag, depending on the type of link.
Link
div() public ¶
div( string $class = null , string $text = null , array $options = array() )
Returns a formatted DIV tag for HTML FORMs.
Options
escape
Whether or not the contents should be html_entity escaped.
Parameters
- string $class optional null
- CSS class name of the div element.
- string $text optional null
String content that will appear inside the div element. If null, only a start tag will be printed
- array $options optional array()
- Additional HTML attributes of the DIV tag
Returns
The formatted DIV element
Link
docType() public ¶
docType( string $type = 'xhtml-strict' )
Returns a doctype string.
Possible doctypes:
- html4-strict: HTML4 Strict.
- html4-trans: HTML4 Transitional.
- html4-frame: HTML4 Frameset.
- html5: HTML5.
- xhtml-strict: XHTML1 Strict.
- xhtml-trans: XHTML1 Transitional.
- xhtml-frame: XHTML1 Frameset.
- xhtml11: XHTML1.1.
Parameters
- string $type optional 'xhtml-strict'
- Doctype to use.
Returns
Doctype string
Link
getCrumbList() public ¶
getCrumbList( array $options = array() )
Returns breadcrumbs as a (x)html list
This method uses HtmlHelper::tag() to generate list and its elements. Works similar to HtmlHelper::getCrumbs(), so it uses options which every crumb was added with.
Parameters
- array $options optional array()
- Array of html attributes to apply to the generated list elements.
Returns
breadcrumbs html list
Link
getCrumbs() public ¶
getCrumbs( string $separator = '»' , string $startText = false )
Returns the breadcrumb trail as a sequence of »-separated links.
Parameters
- string $separator optional '»'
- Text to separate crumbs.
- string $startText optional false
- This will be the first crumb, if false it defaults to first crumb in array
Returns
Composed bread crumbs
Link
image() public ¶
image( string $path , array $options = array() )
Creates a formatted IMG element. If $options['url']
is provided, an image link will be
generated with the link pointed at $options['url']
. This method will set an empty
alt attribute if one is not supplied.
Usage
Create a regular image:
echo $html->image('cake_icon.png', array('alt' => 'CakePHP'));
Create an image link:
echo $html->image('cake_icon.png', array('alt' => 'CakePHP', 'url' => 'http://cakephp.org'));
Parameters
- string $path
- Path to the image file, relative to the app/webroot/img/ directory.
- array $options optional array()
- Array of HTML attributes.
Returns
completed img tag
Link
link() public ¶
link( string $title , mixed $url = null , array $options = array() , string $confirmMessage = false )
Creates an HTML link.
If $url starts with "http://" this is treated as an external link. Else, it is treated as a path to controller/action and parsed with the HtmlHelper::url() method.
If the $url is empty, $title is used instead.
Options
escape
Set to false to disable escaping of title and attributes.confirm
JavaScript confirmation message.
Parameters
- string $title
- The content to be wrapped by tags.
- mixed $url optional null
- Cake-relative URL or array of URL parameters, or external URL (starts with http://)
- array $options optional array()
- Array of HTML attributes.
- string $confirmMessage optional false
- JavaScript confirmation message.
Returns
An
<a />
element.Link
loadConfig() public ¶
loadConfig( mixed $configFile , string $path = null )
Load Html tag configuration.
Loads a file from APP/Config that contains tag data. By default the file is expected to be compatible with PhpReader:
$this->Html->loadConfig('tags.php');
tags.php could look like:
{{{ $tags = array( 'meta' => '' ); }}}
If you wish to store tag definitions in another format you can give an array containing the file name, and reader class name:
$this->Html->loadConfig(array('tags.ini', 'ini'));
Its expected that the tags
index will exist from any configuration file that is read.
You can also specify the path to read the configuration file from, if APP/Config is not
where the file is.
$this->Html->loadConfig('tags.php', APP . 'Lib' . DS);
Configuration files can define the following sections:
tags
The tags to replace.minimizedAttributes
The attributes that are represented likedisabled="disabled"
docTypes
Additional doctypes to use.attributeFormat
Format for long attributes e.g.'%s="%s"'
minimizedAttributeFormat
Format for minimized attributes e.g.'%s="%s"'
Parameters
- mixed $configFile
- String with the config file (load using PhpReader) or an array with file and reader name
- string $path optional null
- Path with config file
Returns
False to error or loaded configs
Throws
Link
meta() public ¶
meta( string $type , mixed $url = null , array $options = array() )
Creates a link to an external resource and handles basic meta tags
Options
inline
Whether or not the link element should be output inline, or in scripts_for_layout.
Parameters
- string $type
- The title of the external resource
- mixed $url optional null
- The address of the external resource or string for content attribute
- array $options optional array()
Other attributes for the generated tag. If the type attribute is html, rss, atom, or icon, the mime-type is returned.
Returns
A completed
<link />
element.Link
nestedList() public ¶
nestedList( array $list , array $options = array() , array $itemOptions = array() , string $tag = 'ul' )
Build a nested list (UL/OL) out of an associative array.
Parameters
- array $list
- Set of elements to list
- array $options optional array()
- Additional HTML attributes of the list (ol/ul) tag or if ul/ol use that as tag
- array $itemOptions optional array()
- Additional HTML attributes of the list item (LI) tag
- string $tag optional 'ul'
- Type of list tag to use (ol/ul)
Returns
The nested list
Link
para() public ¶
para( string $class , string $text , array $options = array() )
Returns a formatted P tag.
Options
escape
Whether or not the contents should be html_entity escaped.
Parameters
- string $class
- CSS class name of the p element.
- string $text
- String content that will appear inside the p element.
- array $options optional array()
- Additional HTML attributes of the P tag
Returns
The formatted P element
Link
script() public ¶
script( mixed $url , mixed $options = array() )
Returns one or many <script>
tags depending on the number of scripts given.
If the filename is prefixed with "/", the path will be relative to the base path of your application. Otherwise, the path will be relative to your JavaScript path, usually webroot/js.
Usage
Include one script file:
echo $this->Html->script('styles.js');
Include multiple script files:
echo $this->Html->script(array('one.js', 'two.js'));
Add the script file to the $scripts_for_layout
layout var:
$this->Html->script('styles.js', array('inline' => false));
Options
inline
- Whether script should be output inline or into scripts_for_layout.once
- Whether or not the script should be checked for uniqueness. If true scripts will only be included once, use false to allow the same script to be included more than once per request.
Parameters
- mixed $url
- String or array of javascript files to include
- mixed $options optional array()
- Array of options, and html attributes see above. If boolean sets $options['inline'] = value
Returns
String of <script />
tags or null if $inline is false or if $once is true and the file has been
included before.
Link
scriptBlock() public ¶
scriptBlock( string $script , array $options = array() )
Wrap $script in a script tag.
Options
safe
(boolean) Whether or not the $script should be wrapped ininline
(boolean) Whether or not the $script should be added to $scripts_for_layout or output inline
Parameters
- string $script
- The script to wrap
- array $options optional array()
- The options to use.
Returns
string or null depending on the value of
$options['inline']
Link
scriptEnd() public ¶
scriptEnd( )
End a Buffered section of Javascript capturing.
Generates a script tag inline or in $scripts_for_layout
depending on the settings
used when the scriptBlock was started
Returns
depending on the settings of scriptStart() either a script tag or null
Link
scriptStart() public ¶
scriptStart( array $options = array() )
Begin a script block that captures output until HtmlHelper::scriptEnd() is called. This capturing block will capture all output between the methods and create a scriptBlock from it.
Options
safe
Whether the code block should contain a CDATAinline
Should the generated script tag be output inline or in$scripts_for_layout
Parameters
- array $options optional array()
- Options for the code block.
Link
style() public ¶
style( array $data , boolean $oneline = true )
Builds CSS style data from an array of CSS properties
Usage:
{{{ echo $html->style(array('margin' => '10px', 'padding' => '10px'), true);
// creates 'margin:10px;padding:10px;' }}}
Parameters
- array $data
- Style data array, keys will be used as property names, values as property values.
- boolean $oneline optional true
- Whether or not the style block should be displayed on one line.
Returns
CSS styling data
Link
tableCells() public ¶
tableCells( array $data , array $oddTrOptions = null , array $evenTrOptions = null , boolean $useCount = false , boolean $continueOddEven = true )
Returns a formatted string of table rows (TR's with TD's in them).
Parameters
- array $data
- Array of table data
- array $oddTrOptions optional null
- HTML options for odd TR elements if true useCount is used
- array $evenTrOptions optional null
- HTML options for even TR elements
- boolean $useCount optional false
- adds class "column-$i"
- boolean $continueOddEven optional true
If false, will use a non-static $count variable, so that the odd/even count is reset to zero just for that call.
Returns
Formatted HTML
Link
tableHeaders() public ¶
tableHeaders( array $names , array $trOptions = null , array $thOptions = null )
Returns a row of formatted and named TABLE headers.
Parameters
- array $names
- Array of tablenames.
- array $trOptions optional null
- HTML options for TR elements.
- array $thOptions optional null
- HTML options for TH elements.
Returns
Completed table headers
Link
tag() public ¶
tag( string $name , string $text = null , array $options = array() )
Returns a formatted block tag, i.e DIV, SPAN, P.
Options
escape
Whether or not the contents should be html_entity escaped.
Parameters
- string $name
- Tag name.
- string $text optional null
String content that will appear inside the div element. If null, only a start tag will be printed
- array $options optional array()
- Additional HTML attributes of the DIV tag, see above.
Returns
The formatted tag element
Link
Methods inherited from Helper
__call() public ¶
__call( string $method , array $params )
Provide non fatal errors on missing method calls.
Parameters
- string $method
- Method to invoke
- array $params
- Array of params for the method.
__get() public ¶
__get( string $name )
Lazy loads helpers. Provides access to deprecated request properties as well.
Parameters
- string $name
- Name of the property being accessed.
Returns
Helper or property found at $name
__set() public ¶
__set( string $name , mixed $value )
Provides backwards compatibility access for setting values to the request object.
Parameters
- string $name
- Name of the property being accessed.
- mixed $value
Returns
Return the $value
_formatAttribute() protected deprecated ¶
_formatAttribute( string $key , string $value , boolean $escape = true )
Formats an individual attribute, and returns the string value of the composed attribute. Works with minimized attributes that have the same value as their name such as 'disabled' and 'checked'
Deprecated
Parameters
- string $key
- The name of the attribute to create
- string $value
- The value of the attribute to create.
- boolean $escape optional true
- Define if the value must be escaped
Returns
The composed attribute.
_initInputField() protected ¶
_initInputField( string $field , array $options = array() )
Sets the defaults for an input tag. Will set the name, value, and id attributes for an array of html attributes. Will also add a 'form-error' class if the field contains validation errors.
Parameters
- string $field
- The field name to initialize.
- array $options optional array()
- Array of options to use while initializing an input field.
Returns
Array options for the form input.
_name() protected ¶
_name( mixed $options = array() , string $field = null , string $key = 'name' )
Gets the input field name for the current tag. Creates input name attributes using CakePHP's data[Model][field] formatting.
Parameters
- mixed $options optional array()
If an array, should be an array of attributes that $key needs to be added to. If a string or null, will be used as the View entity.
- string $field optional null
- string $key optional 'name'
- The name of the attribute to be set, defaults to 'name'
Returns
If an array was given for $options, an array with $key set will be returned. If a string was supplied a string will be returned.
_parseAttributes() protected deprecated ¶
_parseAttributes( array $options , array $exclude = null , string $insertBefore = ' ' , string $insertAfter = null )
Returns a space-delimited string with items of the $options array. If a key of $options array happens to be one of:
- 'compact'
- 'checked'
- 'declare'
- 'readonly'
- 'disabled'
- 'selected'
- 'defer'
- 'ismap'
- 'nohref'
- 'noshade'
- 'nowrap'
- 'multiple'
- 'noresize'
And its value is one of:
- '1' (string)
- 1 (integer)
- true (boolean)
- 'true' (string)
Then the value will be reset to be identical with key's name. If the value is not one of these 3, the parameter is not output.
'escape' is a special option in that it controls the conversion of attributes to their html-entity encoded equivalents. Set to false to disable html-encoding.
If value for any option key is set to null
or false
, that option will be excluded from output.
Deprecated
Parameters
- array $options
- Array of options.
- array $exclude optional null
- Array of options to be excluded, the options here will not be part of the return.
- string $insertBefore optional ' '
- String to be inserted before options.
- string $insertAfter optional null
- String to be inserted after options.
Returns
Composed attributes.
_selectedArray() protected ¶
_selectedArray( mixed $data , string $key = 'id' )
Transforms a recordset from a hasAndBelongsToMany association to a list of selected options for a multiple select element
Parameters
- mixed $data
- string $key optional 'id'
Returns
addClass() public ¶
addClass( array $options = array() , string $class = null , string $key = 'class' )
Adds the given class to the element options
Parameters
- array $options optional array()
- Array options/attributes to add a class to
- string $class optional null
- The classname being added.
- string $key optional 'class'
- the key to use for class.
Returns
Array of options with $key set.
afterLayout() public ¶
afterLayout( string $layoutFile )
After layout callback. afterLayout is called after the layout has rendered.
Overridden in subclasses.
Parameters
- string $layoutFile
- The layout file that was rendered.
afterRender() public ¶
afterRender( string $viewFile )
After render callback. afterRender is called after the view file is rendered but before the layout has been rendered.
Overridden in subclasses.
Parameters
- string $viewFile
- The view file that was rendered.
assetTimestamp() public ¶
assetTimestamp( string $path )
Adds a timestamp to a file based resource based on the value of Asset.timestamp
in
Configure. If Asset.timestamp is true and debug > 0, or Asset.timestamp == 'force'
a timestamp will be added.
Parameters
- string $path
- The file path to timestamp, the path must be inside WWW_ROOT
Returns
Path with a timestamp added, or not.
beforeLayout() public ¶
beforeLayout( string $layoutFile )
Before layout callback. beforeLayout is called before the layout is rendered.
Overridden in subclasses.
Parameters
- string $layoutFile
- The layout about to be rendered.
beforeRender() public ¶
beforeRender( string $viewFile )
Before render callback. beforeRender is called before the view file is rendered.
Overridden in subclasses.
Parameters
- string $viewFile
- The view file that is going to be rendered
clean() public ¶
clean( mixed $output )
Used to remove harmful tags from content. Removes a number of well known XSS attacks from content. However, is not guaranteed to remove all possibilities. Escaping content is the best way to prevent all possible attacks.
Parameters
- mixed $output
- Either an array of strings to clean or a single string to clean.
Returns
cleaned content for output
domId() public ¶
domId( mixed $options = null , string $id = 'id' )
Generates a DOM ID for the selected element, if one is not set. Uses the current View::entity() settings to generate a CamelCased id attribute.
Parameters
- mixed $options optional null
Either an array of html attributes to add $id into, or a string with a view entity path to get a domId for.
- string $id optional 'id'
- The name of the 'id' attribute.
Returns
If $options was an array, an array will be returned with $id set. If a string was supplied, a string will be returned.
entity() public ¶
entity( )
Returns the entity reference of the current context as an array of identity parts
Returns
An array containing the identity elements of an entity
field() public ¶
field( )
Gets the currently-used model field of the rendering context. Strips off field suffixes such as year, month, day, hour, min, meridian when the current entity is longer than 2 elements.
Returns
output() public deprecated ¶
output( string $str )
Returns a string generated by a helper method
This method can be overridden in subclasses to do generalized output post-processing
Deprecated
Parameters
- string $str
- String to be output.
Returns
setEntity() public ¶
setEntity( mixed $entity , boolean $setScope = false )
Sets this helper's model and field properties to the dot-separated value-pair in $entity.
Parameters
- mixed $entity
- A field name, like "ModelName.fieldName" or "ModelName.ID.fieldName"
- boolean $setScope optional false
- Sets the view scope to the model specified in $tagValue
url() public ¶
url( mixed $url = null , boolean $full = false )
Finds URL for specified action.
Returns a URL pointing at the provided parameters.
Parameters
- mixed $url optional null
Either a relative string url like
/products/view/23
or an array of url parameters. Using an array for urls will allow you to leverage the reverse routing features of CakePHP.- boolean $full optional false
- If true, the full base URL will be prepended to the result
Returns
Full translated URL with base path.
Link
value() public ¶
value( mixed $options = array() , string $field = null , string $key = 'value' )
Gets the data for the current tag
Parameters
- mixed $options optional array()
If an array, should be an array of attributes that $key needs to be added to. If a string or null, will be used as the View entity.
- string $field optional null
- string $key optional 'value'
- The name of the attribute to be set, defaults to 'value'
Returns
If an array was given for $options, an array with $key set will be returned. If a string was supplied a string will be returned.
Methods inherited from Object
_mergeVars() protected ¶
_mergeVars( array $properties , string $class , boolean $normalize = true )
Merges this objects $property with the property in $class' definition. This classes value for the property will be merged on top of $class'
This provides some of the DRY magic CakePHP provides. If you want to shut it off, redefine this method as an empty function.
Parameters
- array $properties
- The name of the properties to merge.
- string $class
- The class to merge the property with.
- boolean $normalize optional true
- Set to true to run the properties through Set::normalize() before merging.
_set() protected ¶
_set( array $properties = array() )
Allows setting of multiple properties of the object in a single line of code. Will only set properties that are part of a class declaration.
Parameters
- array $properties optional array()
- An associative array containing properties and corresponding values.
_stop() protected ¶
_stop( integer|string $status = 0 )
Stop execution of the current script. Wraps exit() making testing easier.
Parameters
- integer|string $status optional 0
- see http://php.net/exit for values
dispatchMethod() public ¶
dispatchMethod( string $method , array $params = array() )
Calls a method on this object with the given parameters. Provides an OO wrapper
for call_user_func_array
Parameters
- string $method
- Name of the method to call
- array $params optional array()
- Parameter list to use when calling $method
Returns
Returns the result of the method call
log() public ¶
log( string $msg , integer $type = LOG_ERROR )
Convenience method to write a message to CakeLog. See CakeLog::write() for more information on writing to logs.
Parameters
- string $msg
- Log message
- integer $type optional LOG_ERROR
- Error type constant. Defined in app/Config/core.php.
Returns
Success of log write
requestAction() public ¶
requestAction( mixed $url , array $extra = array() )
Calls a controller's method from any location. Can be used to connect controllers together or tie plugins into a main application. requestAction can be used to return rendered views or fetch the return value from controller actions.
Under the hood this method uses Router::reverse() to convert the $url parameter into a string URL. You should use URL formats that are compatible with Router::reverse()
Passing POST and GET data
POST and GET data can be simulated in requestAction. Use $extra['url']
for
GET data. The $extra['data']
parameter allows POST data simulation.
Parameters
- mixed $url
String or array-based url. Unlike other url arrays in CakePHP, this url will not automatically handle passed and named arguments in the $url parameter.
- array $extra optional array()
if array includes the key "return" it sets the AutoRender to true. Can also be used to submit GET/POST data, and named/passed arguments.
Returns
Boolean true or false on success/failure, or contents of rendered action if 'return' is set in $extra.
toString() public ¶
toString( )
Object-to-string conversion. Each class can override this method as necessary.
Returns
The name of this class
Properties detail
$_docTypes ¶
Document type definitions
array( 'html4-strict' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">', 'html4-trans' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">', 'html4-frame' => '<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">', 'html5' => '<!DOCTYPE html>', 'xhtml-strict' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">', 'xhtml-trans' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">', 'xhtml-frame' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-frameset.dtd">', 'xhtml11' => '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">' )
$_minimizedAttributes ¶
Minimized attributes
array( 'compact', 'checked', 'declare', 'readonly', 'disabled', 'selected', 'defer', 'ismap', 'nohref', 'noshade', 'nowrap', 'multiple', 'noresize' )
$_scriptBlockOptions ¶
Options for the currently opened script block buffer if any.
array()
$_tags ¶
html tags used by this helper.
array( 'meta' => '<meta%s/>', 'metalink' => '<link href="%s"%s/>', 'link' => '<a href="%s"%s>%s</a>', 'mailto' => '<a href="mailto:%s" %s>%s</a>', 'form' => '<form action="%s"%s>', 'formend' => '</form>', 'input' => '<input name="%s"%s/>', 'textarea' => '<textarea name="%s"%s>%s</textarea>', 'hidden' => '<input type="hidden" name="%s"%s/>', 'checkbox' => '<input type="checkbox" name="%s" %s/>', 'checkboxmultiple' => '<input type="checkbox" name="%s[]"%s />', 'radio' => '<input type="radio" name="%s" id="%s"%s />%s', 'selectstart' => '<select name="%s"%s>', 'selectmultiplestart' => '<select name="%s[]"%s>', 'selectempty' => '<option value=""%s> </option>', 'selectoption' => '<option value="%s"%s>%s</option>', 'selectend' => '</select>', 'optiongroup' => '<optgroup label="%s"%s>', 'optiongroupend' => '</optgroup>', 'checkboxmultiplestart' => '', 'checkboxmultipleend' => '', 'password' => '<input type="password" name="%s" %s/>', 'file' => '<input type="file" name="%s" %s/>', 'file_no_model' => '<input type="file" name="%s" %s/>', 'submit' => '<input %s/>', 'submitimage' => '<input type="image" src="%s" %s/>', 'button' => '<button type="%s"%s>%s</button>', 'image' => '<img src="%s" %s/>', 'tableheader' => '<th%s>%s</th>', 'tableheaderrow' => '<tr%s>%s</tr>', 'tablecell' => '<td%s>%s</td>', 'tablerow' => '<tr%s>%s</tr>', 'block' => '<div%s>%s</div>', 'blockstart' => '<div%s>', 'blockend' => '</div>', 'tag' => '<%s%s>%s</%s>', 'tagstart' => '<%s%s>', 'tagend' => '</%s>', 'tagselfclosing' => '<%s%s/>', 'para' => '<p%s>%s</p>', 'parastart' => '<p%s>', 'label' => '<label for="%s"%s>%s</label>', 'fieldset' => '<fieldset%s>%s</fieldset>', 'fieldsetstart' => '<fieldset><legend>%s</legend>', 'fieldsetend' => '</fieldset>', 'legend' => '<legend>%s</legend>', 'css' => '<link rel="%s" type="text/css" href="%s" %s/>', 'style' => '<style type="text/css"%s>%s</style>', 'charset' => '<meta http-equiv="Content-Type" content="text/html; charset=%s" />', 'ul' => '<ul%s>%s</ul>', 'ol' => '<ol%s>%s</ol>', 'li' => '<li%s>%s</li>', 'error' => '<div%s>%s</div>', 'javascriptblock' => '<script type="text/javascript"%s>%s</script>', 'javascriptstart' => '<script type="text/javascript">', 'javascriptlink' => '<script type="text/javascript" src="%s"%s></script>', 'javascriptend' => '</script>' )