From 0baafc173a0065e5cc748616eb574fdf30a5a540 Mon Sep 17 00:00:00 2001 From: iarenaza Date: Tue, 9 Oct 2007 21:43:28 +0000 Subject: [PATCH] Fix MDL-11632: Multiple files with emtpy lines outside PHP open/close tags There are multiple issues with Moodle files containing empty or blank lines (lines consisting of white spaces or tabs only) and/or white space before or after the PHP open and close tags, notably with config.php and theme files. --- auth/cas/languages.php | 1 - course/import/groups/index.php | 1 - course/search.php | 1 - course/user.php | 1 - grade/edit/letter/edit.php | 1 - grade/edit/letter/index.php | 1 - grade/edit/settings/index.php | 1 - lib/adodb/lang/adodb-ar.inc.php | 1 - lib/adodb/lang/adodb-bg.inc.php | 3 +-- lib/adodb/lang/adodb-bgutf8.inc.php | 1 - lib/adodb/lang/adodb-en.inc.php | 3 +-- lib/adodb/lang/adodb-pl.inc.php | 3 +-- lib/adodb/lang/adodb-ro.inc.php | 1 - lib/adodb/lang/adodb_th.inc.php | 1 - lib/adodb/readme_moodle.txt | 7 ++++++- mod/choice/index.php | 1 - mod/exercise/assessments.php | 1 - mod/glossary/tabs.php | 2 +- mod/journal/index.php | 1 - mod/journal/report.php | 1 - mod/label/view.php | 1 - mod/lesson/action/confirmdelete.php | 1 - mod/resource/index.php | 1 - mod/resource/type/repository/hive/openlitepublish.php | 1 - mod/scorm/datamodel.php | 1 - mod/survey/download.php | 1 - mod/workshop/assess.php | 1 - mod/workshop/assessments.php | 1 - mod/workshop/upload.php | 1 - mod/workshop/viewassessment.php | 1 - question/export.php | 1 - sso/hive/login.php | 1 - theme/chameleon/ui/chameleon.php | 2 -- theme/custom_corners/footer.html | 1 - theme/custom_corners/ui/chameleon.php | 2 -- 35 files changed, 10 insertions(+), 40 deletions(-) diff --git a/auth/cas/languages.php b/auth/cas/languages.php index b0d40fa96c..9edb8e768e 100644 --- a/auth/cas/languages.php +++ b/auth/cas/languages.php @@ -15,4 +15,3 @@ $CASLANGUAGES = array ( "french" => "French"); ?> - diff --git a/course/import/groups/index.php b/course/import/groups/index.php index 7dc75208cf..231184f527 100755 --- a/course/import/groups/index.php +++ b/course/import/groups/index.php @@ -217,4 +217,3 @@ function my_file_get_contents($filename, $use_include_path = 0) { } ?> - diff --git a/course/search.php b/course/search.php index 7b27391cd3..c7ff0d658f 100644 --- a/course/search.php +++ b/course/search.php @@ -340,4 +340,3 @@ ?> - diff --git a/course/user.php b/course/user.php index a28f487dbf..59cb41258c 100644 --- a/course/user.php +++ b/course/user.php @@ -306,4 +306,3 @@ function print_outline_row($mod, $instance, $result) { } ?> - diff --git a/grade/edit/letter/edit.php b/grade/edit/letter/edit.php index 2e8a6dcbeb..6ba386285b 100644 --- a/grade/edit/letter/edit.php +++ b/grade/edit/letter/edit.php @@ -122,4 +122,3 @@ $mform->display(); print_footer($COURSE); ?> - diff --git a/grade/edit/letter/index.php b/grade/edit/letter/index.php index 6aceee9c31..93f9a9564c 100644 --- a/grade/edit/letter/index.php +++ b/grade/edit/letter/index.php @@ -57,4 +57,3 @@ print_table($table); print_footer($course); ?> - diff --git a/grade/edit/settings/index.php b/grade/edit/settings/index.php index a64f093125..b9d6ccd56d 100644 --- a/grade/edit/settings/index.php +++ b/grade/edit/settings/index.php @@ -67,4 +67,3 @@ $mform->display(); print_footer($course); ?> - diff --git a/lib/adodb/lang/adodb-ar.inc.php b/lib/adodb/lang/adodb-ar.inc.php index dd0f830f17..d4ef68fc44 100644 --- a/lib/adodb/lang/adodb-ar.inc.php +++ b/lib/adodb/lang/adodb-ar.inc.php @@ -31,4 +31,3 @@ $ADODB_LANG_ARRAY = array ( DB_ERROR_ACCESS_VIOLATION => 'ÓãÇÍíÇÊ ÛíÑ ßÇÝíÉ' ); ?> - diff --git a/lib/adodb/lang/adodb-bg.inc.php b/lib/adodb/lang/adodb-bg.inc.php index 4fb1dc070a..ee307c13fe 100644 --- a/lib/adodb/lang/adodb-bg.inc.php +++ b/lib/adodb/lang/adodb-bg.inc.php @@ -34,5 +34,4 @@ $ADODB_LANG_ARRAY = array ( DB_ERROR_NOSUCHDB => 'íåñúùåñòâóâàùà áàçà äàííè', DB_ERROR_ACCESS_VIOLATION => 'íÿìàòå äîñòàòú÷íî ïðàâà' ); -?> - \ No newline at end of file +?> \ No newline at end of file diff --git a/lib/adodb/lang/adodb-bgutf8.inc.php b/lib/adodb/lang/adodb-bgutf8.inc.php index 1035c5989d..d5c7155c60 100644 --- a/lib/adodb/lang/adodb-bgutf8.inc.php +++ b/lib/adodb/lang/adodb-bgutf8.inc.php @@ -35,4 +35,3 @@ $ADODB_LANG_ARRAY = array ( DB_ERROR_ACCESS_VIOLATION => 'нямате достатъчно права' ); ?> - diff --git a/lib/adodb/lang/adodb-en.inc.php b/lib/adodb/lang/adodb-en.inc.php index ed1b8f19a8..6895995eff 100644 --- a/lib/adodb/lang/adodb-en.inc.php +++ b/lib/adodb/lang/adodb-en.inc.php @@ -30,5 +30,4 @@ $ADODB_LANG_ARRAY = array ( DB_ERROR_NOSUCHDB => 'no such database', DB_ERROR_ACCESS_VIOLATION => 'insufficient permissions' ); -?> - \ No newline at end of file +?> \ No newline at end of file diff --git a/lib/adodb/lang/adodb-pl.inc.php b/lib/adodb/lang/adodb-pl.inc.php index aee5bfdfdc..9d9e390676 100644 --- a/lib/adodb/lang/adodb-pl.inc.php +++ b/lib/adodb/lang/adodb-pl.inc.php @@ -32,5 +32,4 @@ $ADODB_LANG_ARRAY = array ( DB_ERROR_NOSUCHDB => 'nie znaleziono bazy', DB_ERROR_ACCESS_VIOLATION => 'niedostateczne uprawnienia' ); -?> - \ No newline at end of file +?> \ No newline at end of file diff --git a/lib/adodb/lang/adodb-ro.inc.php b/lib/adodb/lang/adodb-ro.inc.php index 7c9aa522b7..8263d822b4 100644 --- a/lib/adodb/lang/adodb-ro.inc.php +++ b/lib/adodb/lang/adodb-ro.inc.php @@ -33,4 +33,3 @@ $ADODB_LANG_ARRAY = array ( DB_ERROR_ACCESS_VIOLATION => 'permisiuni insuficiente' ); ?> - diff --git a/lib/adodb/lang/adodb_th.inc.php b/lib/adodb/lang/adodb_th.inc.php index 745441cc1b..a7288efb57 100644 --- a/lib/adodb/lang/adodb_th.inc.php +++ b/lib/adodb/lang/adodb_th.inc.php @@ -31,4 +31,3 @@ $ADODB_LANG_ARRAY = array ( DB_ERROR_ACCESS_VIOLATION => 'permissions ไม่พอ' ); ?> - diff --git a/lib/adodb/readme_moodle.txt b/lib/adodb/readme_moodle.txt index b73dd799a6..be6ba52dba 100644 --- a/lib/adodb/readme_moodle.txt +++ b/lib/adodb/readme_moodle.txt @@ -21,7 +21,12 @@ Our changes: working properly. Simplified logic (now that we are FETCH_ASSOC). Work in progress for the annoying http://tracker.moodle.org/browse/MDL-6877. Once fixed by adodb guys, we'll return to their official distro. + * lang/adodb-ar.inc.php lang/adodb-bg.inc.php lang/adodb-bgutf8.inc.php + lang/adodb-en.inc.php lang/adodb-pl.inc.php lang/adodb-ro.inc.php + lang/adodb_th.inc.php - Removed leading white space outside PHP open/close tags + (see http://tracker.moodle.org/browse/MDL-11632). -skodak + +skodak,iarenaza $Id$ diff --git a/mod/choice/index.php b/mod/choice/index.php index c3a76da859..27924d75a9 100644 --- a/mod/choice/index.php +++ b/mod/choice/index.php @@ -93,4 +93,3 @@ print_footer($course); ?> - diff --git a/mod/exercise/assessments.php b/mod/exercise/assessments.php index d6b4e2290c..20eea1c1ff 100644 --- a/mod/exercise/assessments.php +++ b/mod/exercise/assessments.php @@ -1178,4 +1178,3 @@ print_footer($course); ?> - diff --git a/mod/glossary/tabs.php b/mod/glossary/tabs.php index ae0144a0bd..fc07aeee45 100644 --- a/mod/glossary/tabs.php +++ b/mod/glossary/tabs.php @@ -107,4 +107,4 @@ break; } echo '
'; -?> +?> diff --git a/mod/journal/index.php b/mod/journal/index.php index 2cdc0e46c7..a71b6c06a1 100644 --- a/mod/journal/index.php +++ b/mod/journal/index.php @@ -60,4 +60,3 @@ print_footer($course); ?> - diff --git a/mod/journal/report.php b/mod/journal/report.php index 6462000950..eb687ae0c9 100644 --- a/mod/journal/report.php +++ b/mod/journal/report.php @@ -145,4 +145,3 @@ print_footer($course); ?> - diff --git a/mod/label/view.php b/mod/label/view.php index 20575ece2b..74a8b30112 100644 --- a/mod/label/view.php +++ b/mod/label/view.php @@ -35,4 +35,3 @@ redirect("$CFG->wwwroot/course/view.php?id=$course->id"); ?> - diff --git a/mod/lesson/action/confirmdelete.php b/mod/lesson/action/confirmdelete.php index a1f2a3a75d..586312a632 100644 --- a/mod/lesson/action/confirmdelete.php +++ b/mod/lesson/action/confirmdelete.php @@ -28,4 +28,3 @@ "lesson.php?action=delete&id=$cm->id&pageid=$pageid&sesskey=".$USER->sesskey, "view.php?id=$cm->id"); ?> - diff --git a/mod/resource/index.php b/mod/resource/index.php index cd7d7e1db5..5172ea1f5e 100644 --- a/mod/resource/index.php +++ b/mod/resource/index.php @@ -87,4 +87,3 @@ print_footer($course); ?> - diff --git a/mod/resource/type/repository/hive/openlitepublish.php b/mod/resource/type/repository/hive/openlitepublish.php index 73151342fb..d0fef9fab8 100644 --- a/mod/resource/type/repository/hive/openlitepublish.php +++ b/mod/resource/type/repository/hive/openlitepublish.php @@ -43,4 +43,3 @@ $query .= '&mklmsstyle='.$stylesheets; redirect($CFG->hiveprotocol .'://'. $CFG->hivehost .':'. $CFG->hiveport .''. $CFG->hivepath .'?'.$query); ?> - diff --git a/mod/scorm/datamodel.php b/mod/scorm/datamodel.php index bcb4dc3a21..d7c6d8766e 100755 --- a/mod/scorm/datamodel.php +++ b/mod/scorm/datamodel.php @@ -79,4 +79,3 @@ } } ?> - diff --git a/mod/survey/download.php b/mod/survey/download.php index 60da14a72b..bb8f28cd11 100644 --- a/mod/survey/download.php +++ b/mod/survey/download.php @@ -309,4 +309,3 @@ ?> - diff --git a/mod/workshop/assess.php b/mod/workshop/assess.php index 5d76f4a9ca..b7b02ecb7b 100644 --- a/mod/workshop/assess.php +++ b/mod/workshop/assess.php @@ -155,4 +155,3 @@ print_footer('none'); ?> - diff --git a/mod/workshop/assessments.php b/mod/workshop/assessments.php index e6c3249b65..b284d597b9 100644 --- a/mod/workshop/assessments.php +++ b/mod/workshop/assessments.php @@ -1364,4 +1364,3 @@ print_footer($course); ?> - diff --git a/mod/workshop/upload.php b/mod/workshop/upload.php index 05c4fa753c..155867b8ca 100644 --- a/mod/workshop/upload.php +++ b/mod/workshop/upload.php @@ -121,4 +121,3 @@ print_footer($course); ?> - diff --git a/mod/workshop/viewassessment.php b/mod/workshop/viewassessment.php index 9207ff3d30..a5238fe0c8 100644 --- a/mod/workshop/viewassessment.php +++ b/mod/workshop/viewassessment.php @@ -92,4 +92,3 @@ print_footer('none'); ?> - diff --git a/question/export.php b/question/export.php index 4e40dc47a5..77babbaecb 100644 --- a/question/export.php +++ b/question/export.php @@ -141,4 +141,3 @@ print_footer($COURSE); ?> - diff --git a/sso/hive/login.php b/sso/hive/login.php index 5bd14c3866..f8fe38cfc1 100644 --- a/sso/hive/login.php +++ b/sso/hive/login.php @@ -20,4 +20,3 @@ } ?> - diff --git a/theme/chameleon/ui/chameleon.php b/theme/chameleon/ui/chameleon.php index aac69aa330..86b3d8c57a 100644 --- a/theme/chameleon/ui/chameleon.php +++ b/theme/chameleon/ui/chameleon.php @@ -28,5 +28,3 @@ if (!empty($THEME->chameleonenabled)) { } } ?> - - diff --git a/theme/custom_corners/footer.html b/theme/custom_corners/footer.html index a9327e411f..3bb3a6d173 100644 --- a/theme/custom_corners/footer.html +++ b/theme/custom_corners/footer.html @@ -1,4 +1,3 @@ - diff --git a/theme/custom_corners/ui/chameleon.php b/theme/custom_corners/ui/chameleon.php index aac69aa330..86b3d8c57a 100644 --- a/theme/custom_corners/ui/chameleon.php +++ b/theme/custom_corners/ui/chameleon.php @@ -28,5 +28,3 @@ if (!empty($THEME->chameleonenabled)) { } } ?> - - -- 2.39.5