Class BeHtmlHelper
BeHtmlHelper class.
Extends CakePHP HtmlHelper adding some functionality
-
HtmlHelper
-
BeHtmlHelper
Methods summary
public
|
|
private
mixed
|
#
parse( mixed $url = null, array $mergeParams = null )
Parses a URL involving Router.
Parses a URL involving Router.
Parameters
- $url
- URL.
- $mergeParams
- Array of URL parameters to be merged to URL.
Returns
mixed Parsed URL.
See
Router::parse()
|
public
string
|
#
link( string $title, mixed $url = null, array $options = null, mixed $confirmMessage = false, array $mergeParams = null )
Returns a formatted link, forcing Router to be involved in URL generation.
Returns a formatted link, forcing Router to be involved in URL generation.
Parameters
- $title
- Text to be wrapped within
<a> tags.
- $url
- URL.
- $options
- Additional HTML attributes.
- $confirmMessage
- JS confirm message.
- $mergeParams
- Array of URL parameters to be merged to URL.
Returns
string HTML tag <a> .
See
HtmlHelper::link()
|
public
string
|
#
url( mixed $url = null, boolean $full = false, array $mergeParams = null )
Returns a URL for the given action, forcing Router to be involved.
Returns a URL for the given action, forcing Router to be involved.
Parameters
- $url
- URL.
- $full
- Full URL.
- $mergeParams
- Array of URL parameters to be merged to URL.
Returns
string URL.
See
Helper::url()
|
public
string
|
#
hyphen( string $text, string|null $lang = null, string[] $excludeSelectors = array('.formula'), string[] $excludeSelectorDefaults = array('pre', 'code', 'embed', 'object', 'iframe', 'img', 'svg', 'video', 'audio', 'script', 'style', 'head', 'sub', 'sup') )
Hyphenate a string.
Parameters
- $text
- Text to be hyphenated.
- $lang
- Text language.
- $excludeSelectors
- CSS selectors of elements to be skipped when hyphenating.
- $excludeSelectorDefaults
- $excludeSelectorsDefault Same as above, but by default. (???)
Returns
string Hyphenated string.
|
public
string
|
#
assetTimestamp( string $path )
Append timestamp to an asset to help invalidate browsers' cache.
Append timestamp to an asset to help invalidate browsers' cache.
Parameters
Returns
string
|