API15:JHTMLGrid/id
From Joomla! Documentation
Template:Description:JHTMLGrid/id
Syntax
id($rowNum, $recId, $checkedOut=false, $name='cid')
| Parameter Name | Default Value | Description |
|---|---|---|
| $rowNum | The row index | |
| $recId | The record id | |
| $checkedOut | false | |
| $name | 'cid' | The name of the form element |
Returns
string
Defined in
libraries/joomla/html/html/grid.php
Importing
jimport( 'joomla.html.html.grid' );
Source Body
function id( $rowNum, $recId, $checkedOut=false, $name='cid' )
{
if ( $checkedOut ) {
return '';
} else {
return '<input type="checkbox" id="cb'.$rowNum.'" name="'.$name.'[]" value="'.$recId.'" onclick="isChecked(this.checked);" />';
}
}
[Edit See Also] Template:SeeAlso:JHTMLGrid/id
Examples
<CodeExamplesForm />