Static Public Member Functions |
| static | fromHTML ($html, $icon=null) |
Protected Member Functions |
| | isURL ($url) |
Constructor & Destructor Documentation
| __construct |
( |
|
$label, |
|
|
|
$url, |
|
|
|
$icon = null, |
|
|
|
$attributes = array() |
|
) |
| |
create a link for a widget
- Parameters
-
| String | $label | Label/content of the link |
| String | $url | URL/Location of the link |
| String | $icon | Icon for the link, defaults to blank.gif |
| array | $attributes | HTML-attributes for the a-tag in an associative array. |
Member Function Documentation
| static fromHTML |
( |
|
$html, |
|
|
|
$icon = null |
|
) |
| |
|
static |
Create link by parsing a html chunk.
- Parameters
-
| String | $html | HTML chunk to parse |
| mixed | $icon | Optional icon |
- Returns
- LinkElement Link element from parsed html
- Exceptions
-
| Exception | if html can not be parsed |
| offsetSet |
( |
|
$offset, |
|
|
|
$value |
|
) |
| |
| static parseAttributes |
( |
|
$text | ) |
|
|
staticprotected |
Parse a string of html attributes into an associative array.
- Parameters
-
| String | $text | String of html attributes |
- Returns
- Array parsed attributes as key => value pairs
- See Also
- https://gist.github.com/rodneyrehm/3070128
Renders the element.
- Returns
- String The rendered content
Reimplemented from WidgetElement.
| setActive |
( |
|
$active = true | ) |
|
Field Documentation
The documentation for this class was generated from the following file: