mirror of
https://github.com/e107inc/e107.git
synced 2025-08-06 22:57:14 +02:00
Added 'active' class to checked checkboxes.
This commit is contained in:
@@ -1296,8 +1296,10 @@ class e_form
|
||||
$options['checked'] = $checked; //comes as separate argument just for convenience
|
||||
|
||||
$text = "";
|
||||
|
||||
$pre = (vartrue($options['label'])) ? "<label class='checkbox'>" : ""; // Bootstrap compatible markup
|
||||
|
||||
$active = ($checked === true) ? " active" : ""; // allow for styling if needed.
|
||||
|
||||
$pre = (vartrue($options['label'])) ? "<label class='checkbox".$active."'>" : ""; // Bootstrap compatible markup
|
||||
$post = (vartrue($options['label'])) ? $options['label']."</label>" : "";
|
||||
unset($options['label']); // not to be used as attribute;
|
||||
|
||||
|
Reference in New Issue
Block a user