From ee5567d1ae5ca67b6cd0677b33b6637e207f8921 Mon Sep 17 00:00:00 2001 From: skodak Date: Wed, 3 Jan 2007 18:53:03 +0000 Subject: [PATCH] MDL-7861 Strict XHTML 1.0 - popup_form() fixes (added div and $formname parameter changed to $formid) --- lib/weblib.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/lib/weblib.php b/lib/weblib.php index c6c614e4f46..9f4184ea1e6 100644 --- a/lib/weblib.php +++ b/lib/weblib.php @@ -919,7 +919,7 @@ function print_textfield ($name, $value, $alt = '',$size=50,$maxlength=0, $retur * @uses $CFG * @param string $common The URL up to the point of the variable that changes * @param array $options Alist of value-label pairs for the popup list - * @param string $formname Name must be unique on the page + * @param string $formid Id must be unique on the page (originaly $formname) * @param string $selected The option that is already selected * @param string $nothing The label for the "no choice" option * @param string $help The name of a help page if help is required @@ -930,7 +930,7 @@ function print_textfield ($name, $value, $alt = '',$size=50,$maxlength=0, $retur * @return string If $return is true then the entire form is returned as a string. * @todo Finish documenting this function
*/ -function popup_form($common, $options, $formname, $selected='', $nothing='choose', $help='', $helptext='', $return=false, $targetwindow='self') { +function popup_form($common, $options, $formid, $selected='', $nothing='choose', $help='', $helptext='', $return=false, $targetwindow='self') { global $CFG; static $go, $choose; /// Locally cached, in case there's lots on a page @@ -955,11 +955,10 @@ function popup_form($common, $options, $formname, $selected='', $nothing='choose $startoutput = '
'; - $output = ''."\n"; if ($nothing != '') { $output .= " \n"; @@ -1033,11 +1032,12 @@ function popup_form($common, $options, $formname, $selected='', $nothing='choose $output .= ''; $output .= ''; - $output .= '
'; + $output .= '
'; + $output .= '
'; $output .= '
'; $output .= ''; $output .= '
' . "\n";