[ Index ]

PHP Cross Reference of MediaWiki-1.24.0

title

Body

[close]

/includes/htmlform/ -> HTMLCheckMatrix.php (summary)

(no description)

File Size: 250 lines (8 kb)
Included or required:0 times
Referenced: 0 times
Includes or requires: 0 files

Defines 1 class

HTMLCheckMatrix:: (9 methods):
  __construct()
  validate()
  getInputHTML()
  isTagForcedOff()
  isTagForcedOn()
  getTableRow()
  loadDataFromRequest()
  getDefault()
  filterDataForSubmit()


Class: HTMLCheckMatrix  - X-Ref

A checkbox matrix
Operates similarly to HTMLMultiSelectField, but instead of using an array of
options, uses an array of rows and an array of columns to dynamically
construct a matrix of options. The tags used to identify a particular cell
are of the form "columnName-rowName"

Options:
- columns
- Required list of columns in the matrix.
- rows
- Required list of rows in the matrix.
- force-options-on
- Accepts array of column-row tags to be displayed as enabled but unavailable to change
- force-options-off
- Accepts array of column-row tags to be displayed as disabled but unavailable to change.
- tooltips
- Optional array mapping row label to tooltip content
- tooltip-class
- Optional CSS class used on tooltip container span. Defaults to mw-icon-question.
__construct( $params )   X-Ref
No description

validate( $value, $alldata )   X-Ref
No description

getInputHTML( $value )   X-Ref
Build a table containing a matrix of checkbox options.
The value of each option is a combination of the row tag and column tag.
mParams['rows'] is an array with row labels as keys and row tags as values.
mParams['columns'] is an array with column labels as keys and column tags as values.

param: array $value Array of the options that should be checked
return: string

isTagForcedOff( $tag )   X-Ref
No description

isTagForcedOn( $tag )   X-Ref
No description

getTableRow( $value )   X-Ref
Get the complete table row for the input, including help text,
labels, and whatever.
We override this function since the label should always be on a separate
line above the options in the case of a checkbox matrix, i.e. it's always
a "vertical-label".

param: string $value The value to set the input to
return: string Complete HTML table row

loadDataFromRequest( $request )   X-Ref

param: WebRequest $request
return: array

getDefault()   X-Ref
No description

filterDataForSubmit( $data )   X-Ref
No description



Generated: Fri Nov 28 14:03:12 2014 Cross-referenced by PHPXref 0.7.1