JHtmlJGrid
Utility class for creating HTML Grids
package |
Joomla.Platform |
---|---|
subpackage |
HTML |
since |
11.1 |
Methods
action
Returns an action on a grid
action(integer $i, string $task, string|array $prefix = '', string $text = '', string $active_title = '', string $inactive_title = '', boolean $tip = false, string $active_class = '', string $inactive_class = '', boolean $enabled = true, boolean $translate = true, string $checkbox = 'cb') : string
since |
11.1 |
---|
Arguments
- $i
integer
The row index- $task
string
The task to fire- $prefix
string|array
An optional task prefix or an array of options- $text
string
An optional text to display- $active_title
string
An optional active tooltip to display if $enable is true- $inactive_title
string
An optional inactive tooltip to display if $enable is true- $tip
boolean
An optional setting for tooltip- $active_class
string
An optional active HTML class- $inactive_class
string
An optional inactive HTML class- $enabled
boolean
An optional setting for access control on the action.- $translate
boolean
An optional setting for translation.- $checkbox
string
An optional prefix for checkboxes.
Response
string
The Html code
checkedout
Returns a checked-out icon
checkedout(integer $i, string $editorName, string $time, string|array $prefix = '', boolean $enabled = false, string $checkbox = 'cb') : string
since |
11.1 |
---|
Arguments
- $i
integer
The row index.- $editorName
string
The name of the editor.- $time
string
The time that the object was checked out.- $prefix
string|array
An optional task prefix or an array of options- $enabled
boolean
True to enable the action.- $checkbox
string
An optional prefix for checkboxes.
Response
string
The required HTML.
isdefault
Returns a isDefault state on a grid
isdefault(integer $value, integer $i, string|array $prefix = '', boolean $enabled = true, string $checkbox = 'cb') : string
see | \JHtmlJGrid::state |
---|---|
since |
11.1 |
Arguments
- $value
integer
The state value.- $i
integer
The row index- $prefix
string|array
An optional task prefix or an array of options- $enabled
boolean
An optional setting for access control on the action.- $checkbox
string
An optional prefix for checkboxes.
Response
string
The HTML code
orderDown
Creates a order-down action icon.
orderDown(integer $i, string $task = 'orderdown', string|array $prefix = '', string $text = 'JLIB_HTML_MOVE_DOWN', boolean $enabled = true, string $checkbox = 'cb') : string
since |
11.1 |
---|
Arguments
- $i
integer
The row index.- $task
string
An optional task to fire.- $prefix
string|array
An optional task prefix or an array of options- $text
string
An optional text to display- $enabled
boolean
An optional setting for access control on the action.- $checkbox
string
An optional prefix for checkboxes.
Response
string
The required HTML.
orderUp
Creates a order-up action icon.
orderUp(integer $i, string $task = 'orderup', string|array $prefix = '', string $text = 'JLIB_HTML_MOVE_UP', boolean $enabled = true, string $checkbox = 'cb') : string
since |
11.1 |
---|
Arguments
- $i
integer
The row index.- $task
string
An optional task to fire.- $prefix
string|array
An optional task prefix or an array of options- $text
string
An optional text to display- $enabled
boolean
An optional setting for access control on the action.- $checkbox
string
An optional prefix for checkboxes.
Response
string
The required HTML.
published
Returns a published state on a grid
published(integer $value, integer $i, string|array $prefix = '', boolean $enabled = true, string $checkbox = 'cb', string $publish_up = null, string $publish_down = null) : string
see | \JHtmlJGrid::state |
---|---|
since |
11.1 |
Arguments
- $value
integer
The state value.- $i
integer
The row index- $prefix
string|array
An optional task prefix or an array of options- $enabled
boolean
An optional setting for access control on the action.- $checkbox
string
An optional prefix for checkboxes.- $publish_up
string
An optional start publishing date.- $publish_down
string
An optional finish publishing date.
Response
string
The Html code
publishedOptions
Returns an array of standard published state filter options.
publishedOptions(array $config = array()) : string
since |
11.1 |
---|
Arguments
- $config
array
An array of configuration options. This array can contain a list of key/value pairs where values are boolean and keys can be taken from 'published', 'unpublished', 'archived', 'trash', 'all'. These pairs determine which values are displayed.
Response
string
The HTML code for the select tag
state
Returns a state on a grid
state(array $states, integer $value, integer $i, string|array $prefix = '', boolean $enabled = true, boolean $translate = true, string $checkbox = 'cb') : string
since |
11.1 |
---|
Arguments
- $states
array
array of value/state. Each state is an array of the form (task, text, title,html active class, HTML inactive class) or ('task'=>task, 'text'=>text, 'active_title'=>active title, 'inactive_title'=>inactive title, 'tip'=>boolean, 'active_class'=>html active class, 'inactive_class'=>html inactive class)- $value
integer
The state value.- $i
integer
The row index- $prefix
string|array
An optional task prefix or an array of options- $enabled
boolean
An optional setting for access control on the action.- $translate
boolean
An optional setting for translation.- $checkbox
string
An optional prefix for checkboxes.
Response
string
The Html code