summaryrefslogtreecommitdiff
path: root/includes/sys_form.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/sys_form.php')
-rw-r--r--includes/sys_form.php18
1 files changed, 9 insertions, 9 deletions
diff --git a/includes/sys_form.php b/includes/sys_form.php
index 9cb6f38d..cd1c84e6 100644
--- a/includes/sys_form.php
+++ b/includes/sys_form.php
@@ -38,12 +38,12 @@ function form_spinner($name, $label, $value)
</div>
</div>
<script type="text/javascript">
- $("#spinner-' . $name . '-down").click(function() {
- var spinner = $("#spinner-' . $name . '");
+ $(\'#spinner-' . $name . '-down\').click(function() {
+ var spinner = $(\'#spinner-' . $name . '\');
spinner.val(parseInt(spinner.val()) - 1);
});
- $("#spinner-' . $name . '-up").click(function() {
- var spinner = $("#spinner-' . $name . '");
+ $(\'#spinner-' . $name . '-up\').click(function() {
+ var spinner = $(\'#spinner-' . $name . '\');
spinner.val(parseInt(spinner.val()) + 1);
});
</script>
@@ -157,17 +157,17 @@ function form_multi_checkboxes($names, $label, $items, $selected, $disabled = []
* @param string $label
* @param string $selected
* @param string $value
- * @param string $id
+ * @param string $html_id
* @return string
*/
-function form_checkbox($name, $label, $selected, $value = 'checked', $id = null)
+function form_checkbox($name, $label, $selected, $value = 'checked', $html_id = null)
{
- if (is_null($id)) {
- $id = $name;
+ if (is_null($html_id)) {
+ $html_id = $name;
}
return '<div class="checkbox"><label>'
- . '<input type="checkbox" id="' . $id . '" name="' . $name . '" value="' . htmlspecialchars($value) . '" '
+ . '<input type="checkbox" id="' . $html_id . '" name="' . $name . '" value="' . htmlspecialchars($value) . '" '
. ($selected ? ' checked="checked"' : '') . ' /> '
. $label
. '</label></div>';