mirror of
https://github.com/monstra-cms/monstra.git
synced 2025-08-04 04:07:59 +02:00
Merge pull request #16 from mbarzda/patch-4
Form Helper: adding id atributtes for form inputs
This commit is contained in:
@@ -136,6 +136,9 @@
|
||||
|
||||
// Set the input name
|
||||
$attributes['name'] = $name;
|
||||
|
||||
// Set the input id
|
||||
$attributes['id'] = (isset($attributes['id']))?$attributes['id']:$name;
|
||||
|
||||
// Set the input value
|
||||
$attributes['value'] = $value;
|
||||
@@ -286,6 +289,9 @@
|
||||
|
||||
// Set the input name
|
||||
$attributes['name'] = $name;
|
||||
|
||||
// Set the input id
|
||||
$attributes['id'] = (isset($attributes['id']))?$attributes['id']:$name;
|
||||
|
||||
return '<textarea'.Html::attributes($attributes).'>'.$body.'</textarea>';
|
||||
}
|
||||
@@ -310,6 +316,9 @@
|
||||
// Set the input name
|
||||
$attributes['name'] = $name;
|
||||
|
||||
// Set the input id
|
||||
$attributes['id'] = (isset($attributes['id']))?$attributes['id']:$name;
|
||||
|
||||
$options_output = '';
|
||||
|
||||
foreach ($options as $value => $name) {
|
||||
|
Reference in New Issue
Block a user