Class HtmlHelper
Html Helper class for easy use of HTML widgets.
HtmlHelper encloses all methods needed while working with HTML pages.
- Cake\View\Helper implements Cake\Event\EventListenerInterface uses Cake\Core\InstanceConfigTrait
- Cake\View\Helper\HtmlHelper uses Cake\View\StringTemplateTrait
Link: https://book.cakephp.org/3.0/en/views/helpers/html.html
Location: View/Helper/HtmlHelper.php
Properties summary
-
$_crumbs
protectedarray
Breadcrumbs. -
$_defaultConfig
protectedarray
Default config for this class -
$_docTypes
protectedarray
Document type definitions -
$_includedAssets
protectedarray
Names of script & css files that have been included once -
$_scriptBlockOptions
protectedarray
Options for the currently opened script block buffer if any. -
$helpers
publicarray
List of helpers used by this helper -
$response
publicReference to the Response object
Magic properties summary
-
$Url
public
Inherited Properties
Method Summary
-
__construct() public
Constructor -
_nestedListItem() protected
Internal function to build a nested list (UL/OL) out of an associative array. -
_prepareCrumbs() protected
Prepends startText to crumbs array if set -
_renderCells() protected
Renders cells for a row of a table. -
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. -
implementedEvents() public
Event listeners. -
link() public
Creates an HTML link. -
media() public
Returns an audio/video element -
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 appends to specified view block 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 -
tableCell() public
Renders a single table cell (A TD with attributes). -
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. -
tableRow() public
Renders a single table row (A TR with attributes). -
tag() public
Returns a formatted block tag, i.e DIV, SPAN, P.
Method Detail
__construct() public ¶
__construct( Cake\View\View
$View , array $config [] )
Constructor
Settings
templates
Either a filename to a config containing templates. Or an array of templates to load. See Cake\View\StringTemplate for template formatting.
Customizing tag sets
Using the templates
option you can redefine the tag HtmlHelper will use.
Parameters
-
Cake\View\View
$View - The View this helper is being attached to.
- array $config optional []
- Configuration settings for the helper.
Overrides
_nestedListItem() protected ¶
_nestedListItem( array $items , array $options , array $itemOptions )
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
- Options and additional HTML attributes of the list item (LI) tag.
Returns
The nested list element
See
_prepareCrumbs() protected ¶
_prepareCrumbs( string|array|boolean $startText , boolean $escape true )
Prepends startText to crumbs array if set
Deprecated
Parameters
- string|array|boolean $startText
- Text to prepend
- boolean $escape optional true
- If the output should be escaped or not
Returns
Crumb list including startText (if provided)
_renderCells() protected ¶
_renderCells( array $line , boolean $useCount false )
Renders cells for a row of a table.
This is a helper method for tableCells(). Overload this method as you need to change the behavior of the cell rendering.
Parameters
- array $line
- Line data to render.
- boolean $useCount optional false
- Renders the count into the row. Default is false.
Returns
addCrumb() public ¶
addCrumb( string $name , string|array|null $link null , array $options [] )
Adds a link to the breadcrumbs array.
Deprecated
Parameters
- string $name
- Text for link
- string|array|null $link optional null
- URL for link (if empty it won't be a link)
- array $options optional []
- Link attributes e.g. ['id' => 'selected']
Returns
$this
See
Link
charset() public ¶
charset( string|null $charset null )
Returns a charset META-tag.
Parameters
- string|null $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( string|array $path , array $options [] )
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(['one.css', 'two.css']);
Add the stylesheet to view block "css":
$this->Html->css('styles.css', ['block' => true]);
Add the stylesheet to a custom block:
$this->Html->css('styles.css', ['block' => 'layoutCss']);
Options
block
Set to true to append output to view block "css" or provide custom block name.once
Whether or not the css file should be checked for uniqueness. If true css files will only be included once, use false to allow the same css to be included more than once per request.plugin
False value will prevent parsing path as a pluginrel
Defaults to 'stylesheet'. If equal to 'import' the stylesheet will be imported.fullBase
If true the URL will get a full address for the css file.
Parameters
- string|array $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.- array $options optional []
- Array of options and HTML arguments.
Returns
CSS
<link />
or <style />
tag, depending on the type of link.Link
div() public ¶
div( string|null $class null , string|null $text null , array $options [] )
Returns a formatted DIV tag for HTML FORMs.
Options
escape
Whether or not the contents should be html_entity escaped.
Parameters
- string|null $class optional null
- CSS class name of the div element.
- string|null $text optional null
String content that will appear inside the div element. If null, only a start tag will be printed
- array $options optional []
- Additional HTML attributes of the DIV tag
Returns
The formatted DIV element
docType() public ¶
docType( string $type 'html5' )
Returns a doctype string.
Possible doctypes:
- html4-strict: HTML4 Strict.
- html4-trans: HTML4 Transitional.
- html4-frame: HTML4 Frameset.
- html5: HTML5. Default value.
- xhtml-strict: XHTML1 Strict.
- xhtml-trans: XHTML1 Transitional.
- xhtml-frame: XHTML1 Frameset.
- xhtml11: XHTML1.1.
Parameters
- string $type optional 'html5'
- Doctype to use.
Returns
Doctype string
Link
getCrumbList() public ¶
getCrumbList( array $options [] , string|array|boolean $startText false )
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.
Options
separator
Separator content to insert in between breadcrumbs, defaults to ''firstClass
Class for wrapper tag on the first breadcrumb, defaults to 'first'lastClass
Class for wrapper tag on current active page, defaults to 'last'
Deprecated
Parameters
- array $options optional []
- Array of HTML attributes to apply to the generated list elements.
- string|array|boolean $startText optional false
This will be the first crumb, if false it defaults to first crumb in array. Can also be an array, see
HtmlHelper::getCrumbs
for details.
Returns
Breadcrumbs HTML list.
Link
getCrumbs() public ¶
getCrumbs( string $separator '»' , string|array|boolean $startText false )
Returns the breadcrumb trail as a sequence of »-separated links.
If $startText
is an array, the accepted keys are:
text
Define the text/content for the link.url
Define the target of the created link.
All other keys will be passed to HtmlHelper::link() as the $options
parameter.
Deprecated
Parameters
- string $separator optional '»'
- Text to separate crumbs.
- string|array|boolean $startText optional false
This will be the first crumb, if false it defaults to first crumb in array. Can also be an array, see above for details.
Returns
Composed bread crumbs
Link
image() public ¶
image( string|array $path , array $options [] )
Creates a formatted IMG element.
This method will set an empty alt attribute if one is not supplied.
Usage:
Create a regular image:
echo $this->Html->image('cake_icon.png', ['alt' => 'CakePHP']);
Create an image link:
echo $this->Html->image('cake_icon.png', ['alt' => 'CakePHP', 'url' => 'https://cakephp.org']);
Options:
url
If provided an image link will be generated and the link will point at$options['url']
.fullBase
If true the src attribute will get a full address for the image file.plugin
False value will prevent parsing path as a plugin
Parameters
- string|array $path
- Path to the image file, relative to the app/webroot/img/ directory.
- array $options optional []
- Array of HTML attributes. See above for special options.
Returns
completed img tag
Link
link() public ¶
link( string|array $title , string|array|null $url null , array $options [] )
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 UrlHelper::build() method.
If the $url is empty, $title is used instead.
Options
escape
Set to false to disable escaping of title and attributes.escapeTitle
Set to false to disable escaping of title. Takes precedence over value ofescape
)confirm
JavaScript confirmation message.
Parameters
- string|array $title
The content to be wrapped by
<a>
tags. Can be an array if $url is null. If $url is null, $title will be used as both the URL and title.- string|array|null $url optional null
Cake-relative URL or array of URL parameters, or external URL (starts with http://)
- array $options optional []
- Array of options and HTML attributes.
Returns
An
<a />
element.Link
media() public ¶
media( string|array $path , array $options [] )
Returns an audio/video element
Usage
Using an audio file:
echo $this->Html->media('audio.mp3', ['fullBase' => true]);
Outputs:
<video src="http://www.somehost.com/files/audio.mp3">Fallback text</video>
Using a video file:
echo $this->Html->media('video.mp4', ['text' => 'Fallback text']);
Outputs:
<video src="/files/video.mp4">Fallback text</video>
Using multiple video files:
echo $this->Html->media( ['video.mp4', ['src' => 'video.ogv', 'type' => "video/ogg; codecs='theora, vorbis'"]], ['tag' => 'video', 'autoplay'] );
Outputs:
<video autoplay="autoplay"> <source src="/files/video.mp4" type="video/mp4"/> <source src="/files/video.ogv" type="video/ogv; codecs='theora, vorbis'"/> </video>
Options
tag
Type of media element to generate, either "audio" or "video". If tag is not provided it's guessed based on file's mime type.text
Text to include inside the audio/video tagpathPrefix
Path prefix to use for relative URLs, defaults to 'files/'fullBase
If provided the src attribute will get a full address including domain name
Parameters
- string|array $path
Path to the video file, relative to the webroot/{$options['pathPrefix']} directory. Or an array where each item itself can be a path string or an associate array containing keys
src
andtype
- array $options optional []
- Array of HTML attributes, and special options above.
Returns
Generated media element
meta() public ¶
meta( string|array $type , string|array|null $content null , array $options [] )
Creates a link to an external resource and handles basic meta tags
Create a meta tag that is output inline:
$this->Html->meta('icon', 'favicon.ico');
Append the meta tag to custom view block "meta":
$this->Html->meta('description', 'A great page', ['block' => true]);
Append the meta tag to custom view block:
$this->Html->meta('description', 'A great page', ['block' => 'metaTags']);
Create a custom meta tag:
$this->Html->meta(['property' => 'og:site_name', 'content' => 'CakePHP']);
Options
block
- Set to true to append output to view block "meta" or provide custom block name.
Parameters
- string|array $type
The title of the external resource, Or an array of attributes for a custom meta tag.
- string|array|null $content optional null
- The address of the external resource or string for content attribute
- array $options optional []
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, or null if the element was sent to a block.Link
nestedList() public ¶
nestedList( array $list , array $options [] , array $itemOptions [] )
Build a nested list (UL/OL) out of an associative array.
Options for $options:
tag
- Type of list tag to use (ol/ul)
Options for $itemOptions:
even
- Class to use for even rows.odd
- Class to use for odd rows.
Parameters
- array $list
- Set of elements to list
- array $options optional []
- Options and additional HTML attributes of the list (ol/ul) tag.
- array $itemOptions optional []
- Options and additional HTML attributes of the list item (LI) tag.
Returns
The nested list
Link
para() public ¶
para( string $class , string $text , array $options [] )
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 []
- Additional HTML attributes of the P tag
Returns
The formatted P element
script() public ¶
script( string|array $url , array $options [] )
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(['one.js', 'two.js']);
Add the script file to a custom block:
$this->Html->script('styles.js', ['block' => 'bodyScript']);
Options
block
Set to true to append output to view block "script" or provide custom block name.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.plugin
False value will prevent parsing path as a pluginfullBase
If true the url will get a full address for the script file.
Parameters
- string|array $url
- String or array of javascript files to include
- array $options optional []
- Array of options, and html attributes see above.
Returns
String of <script />
tags or null if block is specified in options
or if $once is true and the file has been included before.
Link
scriptBlock() public ¶
scriptBlock( string $script , array $options [] )
Wrap $script in a script tag.
Options
safe
(boolean) Whether or not the $script should be wrapped in<![CDATA[ ]]>
. Defaults tofalse
.block
Set to true to append output to view block "script" or provide custom block name.
Parameters
- string $script
- The script to wrap
- array $options optional []
The options to use. Options not listed above will be treated as HTML attributes.
Returns
String or null depending on the value of
$options['block']
Link
scriptEnd() public ¶
scriptEnd( )
End a Buffered section of JavaScript capturing. Generates a script tag inline or appends to specified view block 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 [] )
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
(boolean) Whether or not the $script should be wrapped in<![CDATA[ ]]>
. See scriptBlock().block
Set to true to append output to view block "script" or provide custom block name.
Parameters
- array $options optional []
- 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 $this->Html->style(['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
tableCell() public ¶
tableCell( string $content , array $options [] )
Renders a single table cell (A TD with attributes).
Parameters
- string $content
- The content of the cell.
- array $options optional []
- HTML attributes.
Returns
tableCells() public ¶
tableCells( array|string $data , array|boolean|null $oddTrOptions null , array|boolean|null $evenTrOptions null , boolean $useCount false , boolean $continueOddEven true )
Returns a formatted string of table rows (TR's with TD's in them).
Parameters
- array|string $data
- Array of table data
- array|boolean|null $oddTrOptions optional null
- HTML options for odd TR elements if true useCount is used
- array|boolean|null $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. Each tablename also can be a key that points to an array with a set of attributes to its specific tag
- array $trOptions optional null
- HTML options for TR elements.
- array $thOptions optional null
- HTML options for TH elements.
Returns
Completed table headers
Link
tableRow() public ¶
tableRow( string $content , array $options [] )
Renders a single table row (A TR with attributes).
Parameters
- string $content
- The content of the row.
- array $options optional []
- HTML attributes.
Returns
tag() public ¶
tag( string $name , string|null $text null , array $options [] )
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|null $text optional null
String content that will appear inside the div element. If null, only a start tag will be printed
- array $options optional []
- Additional HTML attributes of the DIV tag, see above.
Returns
The formatted tag element
Methods inherited from Cake\View\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.
__debugInfo() public ¶
__debugInfo( )
Returns an array that can be used to describe the internal state of this object.
Returns
__get() public ¶
__get( string $name )
Lazy loads helpers.
Parameters
- string $name
- Name of the property being accessed.
Returns
__set() public ¶
__set( string $name , mixed $value )
Magic setter for removed properties.
Parameters
- string $name
- Property name.
- mixed $value
- Value to set.
_cleanConfirmMessage() protected ¶
_cleanConfirmMessage( string $message )
Returns a string read to be used in confirm()
Parameters
- string $message
- The message to clean
Returns
_confirm() protected ¶
_confirm( string $message , string $okCode , string $cancelCode '' , array $options [] )
Returns a string to be used as onclick handler for confirm dialogs.
Parameters
- string $message
- Message to be displayed
- string $okCode
- Code to be executed after user chose 'OK'
- string $cancelCode optional ''
- Code to be executed after user chose 'Cancel'
- array $options optional []
- Array of options
Returns
onclick JS code
addClass() public ¶
addClass( array $options [] , string|null $class null , string $key 'class' )
Adds the given class to the element options
Parameters
- array $options optional []
- Array options/attributes to add a class to
- string|null $class optional null
- The class name being added.
- string $key optional 'class'
- the key to use for class.
Returns
Array of options with $key set.
initialize() public ¶
initialize( array $config )
Constructor hook method.
Implement this method to avoid having to overwrite the constructor and call parent.
Parameters
- array $config
- The configuration settings provided to this helper.
Methods used from Cake\View\StringTemplateTrait
formatTemplate() public ¶
formatTemplate( string $name , array $data )
Formats a template string with $data
Parameters
- string $name
- The template name.
- array $data
- The data to insert.
Returns
getTemplates() public ¶
getTemplates( string|null $template null )
Gets templates to use or a specific template.
Parameters
- string|null $template optional null
- String for reading a specific template, null for all.
Returns
setTemplates() public ¶
setTemplates( array $templates )
Sets templates to use.
Parameters
- array $templates
- Templates to be added.
Returns
$this
templates() public ¶
templates( string|null|array $templates null )
Gets/sets templates to use.
Deprecated
Parameters
- string|null|array $templates optional null
null or string allow reading templates. An array allows templates to be added.
Returns
$this|string|array
Methods used from Cake\Core\InstanceConfigTrait
_configDelete() protected ¶
_configDelete( string $key )
Deletes a single config key.
Parameters
- string $key
- Key to delete.
Throws
_configRead() protected ¶
_configRead( string|null $key )
Reads a config key.
Parameters
- string|null $key
- Key to read.
Returns
_configWrite() protected ¶
_configWrite( string|array $key , mixed $value , boolean|string $merge false )
Writes a config key.
Parameters
- string|array $key
- Key to write to.
- mixed $value
- Value to write.
- boolean|string $merge optional false
True to merge recursively, 'shallow' for simple merge, false to overwrite, defaults to false.
Throws
config() public ¶
config( string|array|null $key null , mixed|null $value null , boolean $merge true )
Gets/Sets the config.
Usage
Reading the whole config:
$this->config();
Reading a specific value:
$this->config('key');
Reading a nested value:
$this->config('some.nested.key');
Setting a specific value:
$this->config('key', $value);
Setting a nested value:
$this->config('some.nested.key', $value);
Updating multiple config settings at the same time:
$this->config(['one' => 'value', 'another' => 'value']);
Deprecated
Parameters
- string|array|null $key optional null
- The key to get/set, or a complete array of configs.
- mixed|null $value optional null
- The value to set.
- boolean $merge optional true
- Whether to recursively merge or overwrite existing config, defaults to true.
Returns
Config value being read, or the object itself on write operations.
Throws
configShallow() public ¶
configShallow( string|array $key , mixed|null $value null )
Merge provided config with existing config. Unlike config()
which does
a recursive merge for nested keys, this method does a simple merge.
Setting a specific value:
$this->configShallow('key', $value);
Setting a nested value:
$this->configShallow('some.nested.key', $value);
Updating multiple config settings at the same time:
$this->configShallow(['one' => 'value', 'another' => 'value']);
Parameters
- string|array $key
- The key to set, or a complete array of configs.
- mixed|null $value optional null
- The value to set.
Returns
$this
getConfig() public ¶
getConfig( string|null $key null , mixed $default null )
Returns the config.
Usage
Reading the whole config:
$this->getConfig();
Reading a specific value:
$this->getConfig('key');
Reading a nested value:
$this->getConfig('some.nested.key');
Reading with default value:
$this->getConfig('some-key', 'default-value');
Parameters
- string|null $key optional null
- The key to get or null for the whole config.
- mixed $default optional null
- The return value when the key does not exist.
Returns
Config value being read.
setConfig() public ¶
setConfig( string|array $key , mixed|null $value null , boolean $merge true )
Sets the config.
Usage
Setting a specific value:
$this->setConfig('key', $value);
Setting a nested value:
$this->setConfig('some.nested.key', $value);
Updating multiple config settings at the same time:
$this->setConfig(['one' => 'value', 'another' => 'value']);
Parameters
- string|array $key
- The key to set, or a complete array of configs.
- mixed|null $value optional null
- The value to set.
- boolean $merge optional true
- Whether to recursively merge or overwrite existing config, defaults to true.
Returns
$this
Throws
Properties detail
$_defaultConfig ¶
Default config for this class
[ 'templates' => [ 'meta' => '<meta{{attrs}}/>', 'metalink' => '<link href="{{url}}"{{attrs}}/>', 'link' => '<a href="{{url}}"{{attrs}}>{{content}}</a>', 'mailto' => '<a href="mailto:{{url}}"{{attrs}}>{{content}}</a>', 'image' => '<img src="{{url}}"{{attrs}}/>', 'tableheader' => '<th{{attrs}}>{{content}}</th>', 'tableheaderrow' => '<tr{{attrs}}>{{content}}</tr>', 'tablecell' => '<td{{attrs}}>{{content}}</td>', 'tablerow' => '<tr{{attrs}}>{{content}}</tr>', 'block' => '<div{{attrs}}>{{content}}</div>', 'blockstart' => '<div{{attrs}}>', 'blockend' => '</div>', 'tag' => '<{{tag}}{{attrs}}>{{content}}</{{tag}}>', 'tagstart' => '<{{tag}}{{attrs}}>', 'tagend' => '</{{tag}}>', 'tagselfclosing' => '<{{tag}}{{attrs}}/>', 'para' => '<p{{attrs}}>{{content}}</p>', 'parastart' => '<p{{attrs}}>', 'css' => '<link rel="{{rel}}" href="{{url}}"{{attrs}}/>', 'style' => '<style{{attrs}}>{{content}}</style>', 'charset' => '<meta charset="{{charset}}"/>', 'ul' => '<ul{{attrs}}>{{content}}</ul>', 'ol' => '<ol{{attrs}}>{{content}}</ol>', 'li' => '<li{{attrs}}>{{content}}</li>', 'javascriptblock' => '<script{{attrs}}>{{content}}</script>', 'javascriptstart' => '<script>', 'javascriptlink' => '<script src="{{url}}"{{attrs}}></script>', 'javascriptend' => '</script>', 'confirmJs' => '{{confirm}}' ] ]
$_docTypes ¶
Document type definitions
[ '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">' ]
$_scriptBlockOptions ¶
Options for the currently opened script block buffer if any.
[]