From 9986098e42396b223d992902339f742373987de1 Mon Sep 17 00:00:00 2001 From: pdontthink Date: Mon, 14 Mar 2005 00:06:12 +0000 Subject: [PATCH] Why weren't tag IDs part of the parameters to these functions in the first place? Sigh. For now, just use the same as the name, which is OK except for radio buttons, which concatenate value onto the name. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@9014 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- functions/forms.php | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/functions/forms.php b/functions/forms.php index be4709d9..d1a96888 100644 --- a/functions/forms.php +++ b/functions/forms.php @@ -17,9 +17,11 @@ * Helper function to create form fields, not to be called directly, * only by other functions below. */ -function addInputField($type, $name = null, $value = null, $attributes = '') { +function addInputField($type, $name = null, $value = null, $attributes = '', $id = null) { return '\n"; } @@ -45,7 +47,7 @@ function addCheckBox($name, $checked = false, $value = null) { */ function addRadioBox($name, $checked = false, $value = null) { return addInputField('radio', $name, $value, - ($checked ? ' checked="checked"' : '')); + ($checked ? ' checked="checked"' : ''), $name . $value); } /** @@ -144,4 +146,4 @@ function addForm($action, $method = 'post', $name = '', $enctype = '', $charset $enctype . $name . $charset . ">\n"; } -?> \ No newline at end of file +?> -- 2.25.1