From 3fb002215f3624e78231bcd2f321a295e3ad62cf Mon Sep 17 00:00:00 2001 From: tjhunt Date: Tue, 7 Apr 2009 07:40:40 +0000 Subject: [PATCH] weblib: fix bug with disabled pop_form()s --- lib/weblib.php | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/weblib.php b/lib/weblib.php index 96fcc6ba8a..eb6adeaef6 100644 --- a/lib/weblib.php +++ b/lib/weblib.php @@ -959,7 +959,6 @@ function print_textfield ($name, $value, $alt = '',$size=50,$maxlength=0, $retur */ function popup_form($baseurl, $options, $formid, $selected='', $nothing='choose', $help='', $helptext='', $return=false, $targetwindow='self', $selectlabel='', $optionsextra=NULL, $submitvalue='', $disabled=false, $showbutton=false) { - global $CFG, $SESSION; static $go, $choose; /// Locally cached, in case there's lots on a page @@ -980,7 +979,7 @@ function popup_form($baseurl, $options, $formid, $selected='', $nothing='choose' $nothing = $choose.'...'; } if ($disabled) { - $disabled = 'disabled="disabled"'; + $disabled = ' disabled="disabled"'; } else { $disabled = ''; } @@ -1019,7 +1018,7 @@ function popup_form($baseurl, $options, $formid, $selected='', $nothing='choose' $formid.'\').jump.selectedIndex].value;"'; } - $output .= '
'.$selectlabel.$button.''."\n"; if ($nothing != '') { $selectlabeloption = ''; -- 2.39.5