From: gustav_delius Date: Sun, 12 Sep 2004 00:21:21 +0000 (+0000) Subject: some fixes for XHTML compliance X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=0cdd138180cbf0719bc8834fa8b45d228eb959e6;p=moodle.git some fixes for XHTML compliance --- diff --git a/admin/auth.php b/admin/auth.php index fb804b8c33..b44aa21ef7 100644 --- a/admin/auth.php +++ b/admin/auth.php @@ -15,7 +15,7 @@ /// If data submitted, then process and store. - if ($config = data_submitted()) { + if ($config = data_submitted()) { $config = (array)$config; validate_form($config, $err); @@ -35,7 +35,7 @@ $focus = "form.$key"; } } - } + } /// Otherwise fill and print the form. @@ -48,11 +48,11 @@ $options[$module] = get_string("auth_$module"."title", "auth"); } asort($options); - if (isset($_GET['auth'])) { - $auth = $_GET['auth']; - } else { - $auth = $config->auth; - } + if (isset($_GET['auth'])) { + $auth = $_GET['auth']; + } else { + $auth = $config->auth; + } require_once("$CFG->dirroot/auth/$auth/lib.php"); //just to make sure that current authentication functions are loaded if (! isset($config->guestloginbutton)) { $config->guestloginbutton = 1; @@ -89,15 +89,15 @@ $strusers = get_string("users"); print_header("$site->shortname: $strauthenticationoptions", "$site->fullname", - "$stradministration -> $strusers -> $strauthenticationoptions", "$focus"); + "$stradministration -> $strusers -> $strauthenticationoptions", "$focus"); - echo "

"; - echo "

framename}\" NAME=\"authmenu\" method=\"post\" action=\"auth.php\">"; + echo "

"; + echo "framename}\" name=\"authmenu\" method=\"post\" action=\"auth.php\">"; print_string("chooseauthmethod","auth"); - choose_from_menu ($options, "auth", $auth, "","document.location='auth.php?auth='+document.authmenu.auth.options[document.authmenu.auth.selectedIndex].value", ""); + choose_from_menu ($options, "auth", $auth, "","document.location='auth.php?auth='+document.authmenu.auth.options[document.authmenu.auth.selectedIndex].value", ""); - echo "

"; + echo "

"; print_simple_box_start("center", "100%", "$THEME->cellheading"); print_heading($options[$auth]); @@ -106,7 +106,7 @@ print_string("auth_$auth"."description", "auth"); print_simple_box_end(); - echo "
"; + echo "
"; print_heading($strsettings); @@ -116,11 +116,11 @@ if ($auth != "email" and $auth != "none" and $auth != "manual") { echo ""; - echo "

"; + echo "

"; print_string("changepassword", "auth"); echo ":

"; - echo ""; - echo "changepassword\">"; + echo ""; + echo "changepassword\">"; echo ""; echo ""; print_string("changepasswordhelp","auth"); @@ -129,10 +129,10 @@ } echo ""; - echo "

"; + echo "

"; print_string("guestloginbutton", "auth"); echo ":

"; - echo ""; + echo ""; choose_from_menu($guestoptions, "guestloginbutton", $config->guestloginbutton, ""); echo ""; echo ""; @@ -140,17 +140,17 @@ echo ""; if (function_exists('auth_user_create')){ - echo ""; - echo "

"; - print_string("auth_user_create", "auth"); - echo ":

"; - echo ""; - choose_from_menu($createoptions, "auth_user_create", $config->auth_user_create, ""); - echo ""; - echo ""; - print_string("auth_user_creation","auth"); - echo ""; - } + echo ""; + echo "

"; + print_string("auth_user_create", "auth"); + echo ":

"; + echo ""; + choose_from_menu($createoptions, "auth_user_create", $config->auth_user_create, ""); + echo ""; + echo ""; + print_string("auth_user_creation","auth"); + echo ""; + } echo "

$strconfiguration -> ". $strbackup); - echo "

".get_string("logs")."

"; + echo "

".get_string("logs")."

"; print_heading($strbackup); diff --git a/admin/blocks.php b/admin/blocks.php index 95d5947e9b..098e380cf3 100644 --- a/admin/blocks.php +++ b/admin/blocks.php @@ -145,7 +145,7 @@ foreach ($blockbyname as $blockname => $blockid) { // [pj] This is not used anywhere, but I'm leaving it in for the future - //$icon = "name/icon.gif\" hspace=10 height=16 width=16 border=0>"; + //$icon = "name/icon.gif\" hspace="10" height="16" width="16" border="0">"; $blockobject = $blockobjects[$blockid]; $delete = ''.$strdelete.''; diff --git a/admin/config.html b/admin/config.html index 270f46ae39..f642c1c3f3 100644 --- a/admin/config.html +++ b/admin/config.html @@ -1,8 +1,8 @@ - - - +

lang:

+ + @@ -10,8 +10,8 @@ - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - - - + + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + -

lang:

lang, "", "", ""); ?>

langmenu:

langmenu:

langlist:

langlist:

- +

locale:

locale:

- +

timezone:

timezone:

timezone) > 13) { $config->timezone = 99; @@ -71,49 +71,49 @@

country:

country:

country, get_string("selectacountry"), "") ?>

smtphosts:

smtphosts:

- +

smtpuser:

smtpuser:

- + +

smtppass:

smtppass:

- +

noreplyaddress:

noreplyaddress:

- +

gdversion:

gdversion:

maxeditingtime:

maxeditingtime:

longtimenosee:

longtimenosee:

deleteunconfirmed:

deleteunconfirmed:

loglifetime:

loglifetime:

sessiontimeout:

sessiontimeout:

sessioncookie:

sessioncookie:

- +

zip:

zip:

- +

unzip:

unzip:

- +

slasharguments:

slasharguments:

proxyhost:

proxyhost:

- + +

proxyport:

proxyport:

- +

debug:

debug:

framename:

framename:

framename)) { $config->framename = "_top"; } ?> - +

secureforms:

secureforms:

loginhttps:

loginhttps:

teacherassignteachers:

teacherassignteachers:

allusersaresitestudents:

allusersaresitestudents:

showsiteparticipantslist:

showsiteparticipantslist:

allowunenroll:

allowunenroll:

maxbytes:

maxbytes:

fullnamedisplay:

fullnamedisplay:

extendedusernamechars:

extendedusernamechars:

autologinguests:

autologinguests:

forcelogin:

forcelogin:

forceloginforprofiles:

forceloginforprofiles:

opentogoogle:

opentogoogle:

enablerssfeeds:

enablerssfeeds:

digestmailtime:

digestmailtime:

+ ">
diff --git a/admin/delete.php b/admin/delete.php index ca1988a3f0..1404b5ebfa 100644 --- a/admin/delete.php +++ b/admin/delete.php @@ -27,7 +27,7 @@ delete_subdirectories($deletedir); - echo "

Done!

"; + echo "

Done!

"; print_continue($CFG->wwwroot); exit; @@ -43,16 +43,16 @@ function delete_subdirectories($rootdir) { delete_subdirectories($fullfile); echo "Deleting $fullfile ... "; if (rmdir($fullfile)) { - echo "Done.
"; + echo "Done.
"; } else { - echo "FAILED.
"; + echo "FAILED.
"; } } else { echo "Deleting $fullfile ... "; if (unlink("$fullfile")) { - echo "Done.
"; + echo "Done.
"; } else { - echo "FAILED.
"; + echo "FAILED.
"; } } } diff --git a/admin/editor.html b/admin/editor.html index df556f17c4..211e2b6a56 100644 --- a/admin/editor.html +++ b/admin/editor.html @@ -1,7 +1,7 @@ - - + +

htmleditor:

htmleditor:

"; + echo "
"; // print_heading($str->settings); $enrolment->config_form($frm); diff --git a/admin/filters.html b/admin/filters.html index 5f7f10fe5a..79f0c55f10 100644 --- a/admin/filters.html +++ b/admin/filters.html @@ -82,7 +82,7 @@ - + - + - + diff --git a/admin/index.php b/admin/index.php index 72825ab6e5..1164acf594 100644 --- a/admin/index.php +++ b/admin/index.php @@ -21,7 +21,7 @@ /// Check some PHP server settings - $documentationlink = "please read the install documentation"; + $documentationlink = "please read the install documentation"; if (ini_get_bool('session.auto_start')) { error("The PHP server variable 'session.auto_start' should be Off - $documentationlink"); @@ -48,10 +48,10 @@ $dirroot = dirname(realpath("../index.php")); if (!empty($dirroot) and $dirroot != $CFG->dirroot) { error("Please fix your settings in config.php: -

You have: -

\$CFG->dirroot = \"".addslashes($CFG->dirroot)."\"; -

but it should be: -

\$CFG->dirroot = \"".addslashes($dirroot)."\";", +

You have: +

\$CFG->dirroot = \"".addslashes($CFG->dirroot)."\"; +

but it should be: +

\$CFG->dirroot = \"".addslashes($dirroot)."\";", "./"); } @@ -92,7 +92,7 @@ if (empty($agreelicence)) { $strlicense = get_string("license"); print_header($strlicense, $strlicense, $strlicense, "", "", false, " ", " "); - print_heading("Moodle - Modular Object-Oriented Dynamic Learning Environment"); + print_heading("Moodle - Modular Object-Oriented Dynamic Learning Environment"); print_heading(get_string("copyrightnotice")); print_simple_box_start("center"); echo text_to_html(get_string("gpl")); @@ -285,53 +285,53 @@ $table->cellspacing = 3; $table->width = "40%"; - $configdata = " ".get_string("configvariables")." - ". + $configdata = " ".get_string("configvariables")." - ". get_string("adminhelpconfigvariables")."
"; - $configdata .= " ".get_string("sitesettings")." - ". + $configdata .= " ".get_string("sitesettings")." - ". get_string("adminhelpsitesettings")."
"; - $configdata .= " ".get_string("themes")." - ". + $configdata .= " ".get_string("themes")." - ". get_string("adminhelpthemes")."
"; - $configdata .= " ".get_string("language")." - ". + $configdata .= " ".get_string("language")." - ". get_string("adminhelplanguage")."
"; - $configdata .= " ".get_string("managemodules")." - ". + $configdata .= " ".get_string("managemodules")." - ". get_string("adminhelpmanagemodules")."
"; - $configdata .= " ".get_string("manageblocks")." - ". + $configdata .= " ".get_string("manageblocks")." - ". get_string("adminhelpmanageblocks")."
"; - $configdata .= " ".get_string("managefilters")." - ". + $configdata .= " ".get_string("managefilters")." - ". get_string("adminhelpmanagefilters")."
"; if (!isset($CFG->disablescheduledbackups)) { - $configdata .= " ".get_string("backup")." - ". + $configdata .= " ".get_string("backup")." - ". get_string("adminhelpbackup")."
"; } - $configdata .= " ". get_string("editorsettings") ." - ". + $configdata .= " ". get_string("editorsettings") ." - ". get_string("adminhelpeditorsettings")."
"; $table->data[] = array("".get_string("configuration")."", $configdata); - $userdata = " ".get_string("authentication")." - ". + $userdata = " ".get_string("authentication")." - ". get_string("adminhelpauthentication")."
"; - $userdata .= " ".get_string("edituser")." - ". + $userdata .= " ".get_string("edituser")." - ". get_string("adminhelpedituser")."
"; $userdata .= " wwwroot/$CFG->admin/user.php?newuser=true\">". - get_string("addnewuser")." - ". + get_string("addnewuser")." - ". get_string("adminhelpaddnewuser")."
"; $userdata .= " wwwroot/$CFG->admin/uploaduser.php\">". - get_string("uploadusers")." - ". + get_string("uploadusers")." - ". get_string("adminhelpuploadusers")."
"; - $userdata .= "


 ".get_string("enrolments")." - ". + $userdata .= "
 ".get_string("enrolments")." - ". get_string("adminhelpenrolments")."
"; - $userdata .= " ".get_string("assignstudents")." - ". + $userdata .= " ".get_string("assignstudents")." - ". get_string("adminhelpassignstudents")."
"; - $userdata .= " ".get_string("assignteachers")." - ". + $userdata .= " ".get_string("assignteachers")." - ". get_string("adminhelpassignteachers"). - "
"; - $userdata .= " ".get_string("assigncreators")." - ". + "
"; + $userdata .= " ".get_string("assigncreators")." - ". get_string("adminhelpassigncreators")."
"; - $userdata .= " ".get_string("assignadmins")." - ". + $userdata .= " ".get_string("assignadmins")." - ". get_string("adminhelpassignadmins")."
"; $table->data[] = array("".get_string("users")."", $userdata); @@ -355,20 +355,20 @@ "$CFG->release ($CFG->version)
". "Copyright © 1999-2004 Martin Dougiamas
". "GNU Public License"; - echo "

$copyrighttext

"; + echo "

$copyrighttext

"; ////////////////////////////////////////////////////////////////////////////////////////////////// - echo "
:
:
  ">  
"; - echo "
"; + echo ""; + echo ""; - echo ""; - echo ""; echo "
"; print_single_button("$CFG->wwwroot/doc", NULL, get_string("documentation")); echo ""; + echo ""; print_single_button("phpinfo.php", NULL, get_string("phpinfo")); echo ""; + echo ""; print_single_button("register.php", NULL, get_string("registration")); echo "
"; diff --git a/admin/lang.php b/admin/lang.php index 4c4e25a7dc..80e8efe132 100644 --- a/admin/lang.php +++ b/admin/lang.php @@ -25,14 +25,14 @@ switch ($mode) { case "missing": - $navigation = "$strlanguage -> $strmissingstrings"; + $navigation = "$strlanguage -> $strmissingstrings"; $title = $strmissingstrings; $button = ''. ''. ''; break; case "compare": - $navigation = "$strlanguage -> $strcomparelanguage"; + $navigation = "$strlanguage -> $strcomparelanguage"; $title = $strcomparelanguage; $button = '
'. ''. @@ -55,14 +55,14 @@ if (!$mode) { $currlang = current_language(); $langs = get_list_of_languages(); - echo "
"; + echo "
"; echo "$strcurrentlanguage:"; echo ""; echo popup_form ("$CFG->wwwroot/admin/lang.php?lang=", $langs, "chooselang", $currlang, "", "", "", true); echo "
"; print_heading("$strmissingstrings"); print_heading("$strcomparelanguage"); - echo "

"; + echo "

"; $options["lang"] = $currentlang; print_single_button("http://moodle.org/download/lang/", $options, get_string("latestlanguagepack")); echo "
"; @@ -91,7 +91,7 @@ foreach ($stringfiles as $file) { if (!file_exists("$langdir/$file")) { if (!touch("$langdir/$file")) { - echo "

".get_string("filemissing", "", "$langdir/$file")."

"; + echo "

".get_string("filemissing", "", "$langdir/$file")."

"; continue; } } @@ -128,7 +128,7 @@ foreach ($files as $filekey => $file) { // check all the help files. if (!file_exists("$langdir/help/$file")) { - echo "

".get_string("filemissing", "", "$langdir/help/$file")."

"; + echo "

".get_string("filemissing", "", "$langdir/help/$file")."

"; $somethingfound = true; continue; } @@ -139,7 +139,7 @@ } foreach ($files as $filekey => $file) { // check all the docs files. if (!file_exists("$langdir/docs/$file")) { - echo "

".get_string("filemissing", "", "$langdir/docs/$file")."

"; + echo "

".get_string("filemissing", "", "$langdir/docs/$file")."

"; $somethingfound = true; continue; } @@ -182,7 +182,7 @@ if (!file_exists("$langdir/$currentfile")) { if (!touch("$langdir/$currentfile")) { - echo "

".get_string("filemissing", "", "$langdir/$currentfile")."

"; + echo "

".get_string("filemissing", "", "$langdir/$currentfile")."

"; continue; } } @@ -193,7 +193,7 @@ fclose($f); } else { $editable = false; - echo "

".get_string("makeeditable", "", "$langdir/$currentfile")."

"; + echo "

".get_string("makeeditable", "", "$langdir/$currentfile")."

"; } error_reporting(7); @@ -215,7 +215,7 @@ if ($editable) { echo ""; } - echo ""; + echo "
"; foreach ($enstring as $key => $envalue) { $envalue = nl2br(htmlspecialchars($envalue)); $envalue = preg_replace('/(\$a\-\>[a-zA-Z0-9]*|\$a)/', '$0', $envalue); // Make variables bold. @@ -223,8 +223,8 @@ $envalue = str_replace("\\","",$envalue); // Delete all slashes echo "\n\n"; - echo "\n"; - echo "\n"; + echo "\n"; + echo "\n"; $value = $string[$key]; $value = str_replace("\r","",$value); // Bad character caused by Windows @@ -239,7 +239,7 @@ $cellcolour = $value ? $THEME->cellcontent: $THEME->highlight; if ($editable) { - echo ""; } - echo "\n"; + echo "\n"; } else { - echo "\n"; + echo "\n"; } } if ($editable) { - echo "
cellheading\" nowrap valign=top>$keycellheading\" valign=top>$envaluecellheading\" nowrap=\"nowrap\" valign=\"top\">$keycellheading\" valign=\"top\">$envalue\n"; + echo "\n"; if (isset($string[$key])) { $valuelen = strlen($value); } else { @@ -255,14 +255,14 @@ } echo "$value$value
 
"; + echo "
 
"; echo " "; echo " "; echo " "; diff --git a/admin/modules.php b/admin/modules.php index 6b151372dd..434744dc8d 100644 --- a/admin/modules.php +++ b/admin/modules.php @@ -160,7 +160,7 @@ foreach ($modulebyname as $modulename => $module) { - $icon = "name/icon.gif\" hspace=10 height=16 width=16 border=0>"; + $icon = "name/icon.gif\" hspace=\"10\" height=\"16\" width=\"16\" border=\"0\">"; $delete = "name\">$strdelete"; @@ -174,11 +174,11 @@ if ($module->visible) { $visible = "name\" title=\"$strhide\">". - ""; + ""; $class = ""; } else { $visible = "name\" title=\"$strshow\">". - ""; + ""; $class = "class=\"dimmed_text\""; } if ($module->name == "forum") { diff --git a/admin/register.php b/admin/register.php index ba2c3faf8b..a4938edfc7 100644 --- a/admin/register.php +++ b/admin/register.php @@ -49,11 +49,11 @@ print_simple_box_start("center", "", "$THEME->cellheading"); - echo "\n"; - echo "\n"; + echo "\n"; + echo "
\n"; - echo "\n"; - echo "\n"; + echo "\n"; + echo "\n"; echo "\n"; echo "\n"; echo "\n"; @@ -65,27 +65,27 @@ echo "\n"; echo "\n"; - echo "\n"; - echo "\n"; + echo "\n"; + echo "\n"; echo "\n"; echo "version\">\n"; echo "release\">\n"; echo "\n"; - echo "\n"; - echo "\n"; - echo "\n"; + echo "\n"; + echo "\n"; + echo "\n"; echo "\n"; - echo "\n"; - echo "\n"; + echo "\n"; + echo "\n"; echo "\n"; echo "\n"; - echo "\n"; - echo "\n"; + echo "\n"; + echo "\n"; echo "\n"; echo "\n"; - echo "\n"; - echo "\n"; + echo "\n"; - echo "\n"; - echo "\n"; - echo "\n"; + echo "\n"; + echo "\n"; + echo "\n"; echo "\n"; - echo "\n"; - echo "\n"; - echo "\n"; + echo "\n"; + echo "\n"; + echo "\n"; echo "\n"; - echo "\n"; - echo "\n"; + echo "\n"; + echo "\n"; echo "\n"; echo "\n"; - echo "\n"; - echo "\n"; + echo "\n"; + echo "\n"; echo "\n"; echo "\n"; diff --git a/admin/site.html b/admin/site.html index 9199b65d72..21c58ecf64 100644 --- a/admin/site.html +++ b/admin/site.html @@ -1,20 +1,20 @@ > -

Moodle URL:

Moodle URL:

$CFG->wwwroot

".get_string("currentversion").":

".get_string("currentversion").":

$CFG->release ($CFG->version)

".get_string("fullsitename").":

fullname\">

".get_string("fullsitename").":

fullname\">

".get_string("country").":

".get_string("country").":

"; choose_from_menu (get_list_of_countries(), "country", $admin->country, get_string("selectacountry")."...", "", ""); echo "

".get_string("publicdirectory").":

".get_string("publicdirectory").":

"; $options[0] = get_string("publicdirectory0"); $options[1] = get_string("publicdirectory1"); @@ -95,22 +95,22 @@ echo "


\n"; + echo "

\n"; echo "

".get_string("administrator").":

".get_string("administrator").":

".get_string("email").":

email\">

".get_string("email").":

email\">

".get_string("registrationemail").":

".get_string("registrationemail").":

\n"; $options[0] = get_string("registrationno"); $options[1] = get_string("registrationyes"); @@ -119,8 +119,8 @@ echo "

 
 

- - +

:

+ + - - + + - - + - - + + - - + + - - + + - - + + - - + + - - + + - - + +

:

:

:

:


- +

:


+ "; @@ -29,8 +29,8 @@
summary); ?>

:

:

get_string("frontpagenews"), "1" => get_string("frontpagecourselist"), @@ -45,8 +45,8 @@ ?>

:

:

:

:

:

:

()

:

:

()

:

:

()

:

:

() diff --git a/admin/timezone.php b/admin/timezone.php index 17d4bfcdc7..1fb3740f91 100644 --- a/admin/timezone.php +++ b/admin/timezone.php @@ -47,10 +47,10 @@ } } - echo "
"; + echo "
"; echo "$strusers ($strall): "; choose_from_menu ($timezones, "zone", $user->timezone, get_string("serverlocaltime"), "", "99"); - echo ""; + echo ""; echo ""; print_footer(); diff --git a/admin/uploaduser.php b/admin/uploaduser.php index 4575e8e6a5..6817b73158 100755 --- a/admin/uploaduser.php +++ b/admin/uploaduser.php @@ -258,7 +258,7 @@ echo '
'; echo '
'. $strchoose.':'. - ''. + ''. ''. '

'; echo '
'; diff --git a/admin/user.php b/admin/user.php index 8ac5b4d364..c926b5f4c1 100644 --- a/admin/user.php +++ b/admin/user.php @@ -323,10 +323,10 @@ $confirmbutton); } - echo "
"; - echo "
"; - echo ""; - echo ""; + echo "
"; + echo ""; + echo ""; + echo ""; if ($search) { echo ""; } diff --git a/admin/users.php b/admin/users.php index a7b29f1d41..01f962714d 100644 --- a/admin/users.php +++ b/admin/users.php @@ -39,7 +39,7 @@ $table->data[] = array("".get_string("assignstudents")."", get_string("adminhelpassignstudents")); $table->data[] = array("".get_string("assignteachers")."", - get_string("adminhelpassignteachers")." "); + get_string("adminhelpassignteachers")." "); $table->data[] = array("".get_string("assigncreators")."", get_string("adminhelpassigncreators")); $table->data[] = array("".get_string("assignadmins")."",