From: Petr Skoda Date: Sun, 1 Nov 2009 12:34:33 +0000 (+0000) Subject: MDL-20700 coding style cleanup - cvs keywords removed, closign php tag removed, trail... X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=6bfe7aac8bce6167cdfab5b6a182e2e5e8908428;p=moodle.git MDL-20700 coding style cleanup - cvs keywords removed, closign php tag removed, trailing whitespace cleanup --- diff --git a/sso/hive/expired.php b/sso/hive/expired.php index d19cd02b3f..689cadf9da 100644 --- a/sso/hive/expired.php +++ b/sso/hive/expired.php @@ -45,4 +45,3 @@
close_window_button(); -?> diff --git a/sso/hive/lib.php b/sso/hive/lib.php index 758d603d84..468b3d870e 100755 --- a/sso/hive/lib.php +++ b/sso/hive/lib.php @@ -1,4 +1,4 @@ - diff --git a/sso/hive/login.php b/sso/hive/login.php index 1afa920656..c1e105494e 100644 --- a/sso/hive/login.php +++ b/sso/hive/login.php @@ -1,4 +1,4 @@ -wwwroot.'/sso/hive/expired.php'); } - -?> diff --git a/tag/coursetags_add.php b/tag/coursetags_add.php index acdaf1d1bf..b61bba1e99 100644 --- a/tag/coursetags_add.php +++ b/tag/coursetags_add.php @@ -39,5 +39,3 @@ if ($courseid > 0) { } redirect($myurl); - -?> diff --git a/tag/coursetags_edit.php b/tag/coursetags_edit.php index dadf4a79a4..2ada5abfd3 100644 --- a/tag/coursetags_edit.php +++ b/tag/coursetags_edit.php @@ -188,4 +188,3 @@ EOT2; } echo $OUTPUT->footer(); -?> diff --git a/tag/coursetags_more.php b/tag/coursetags_more.php index a49eccb217..094b1ab10c 100644 --- a/tag/coursetags_more.php +++ b/tag/coursetags_more.php @@ -198,4 +198,3 @@ $outstr = ' echo $outstr; echo $OUTPUT->footer(); -?> diff --git a/tag/coursetagslib.php b/tag/coursetagslib.php index 959e342edb..a243e31097 100644 --- a/tag/coursetagslib.php +++ b/tag/coursetagslib.php @@ -266,7 +266,7 @@ function coursetag_get_jscript($coursetagdivs = '') { */ function coursetag_get_jscript_links($coursetagslinks) { global $PAGE; - + if (!empty($coursetagslinks)) { foreach ($coursetagslinks as $a) { $PAGE->requires->js_function_call('add_tag_footer_link', array('coursetagslinks', $a['title'], $a['onclick'], $a['text']))->on_dom_ready(); @@ -656,5 +656,3 @@ function coursetag_get_official_keywords($courseid, $asarray=false) { return $returnstr; } */ - -?> diff --git a/tag/edit.php b/tag/edit.php index 94fee1c7d9..742e352009 100644 --- a/tag/edit.php +++ b/tag/edit.php @@ -1,4 +1,4 @@ -get_data()) { print_error('errorupdatingrecord', 'tag'); } } - + //log tag changes activity //if tag name exist from form, renaming is allow. record log action as rename - //otherwise, record log action as update + //otherwise, record log action as update if (isset($tagnew->name) && ($tag->name != $tagnew->name)){ add_to_log($COURSE->id, 'tag', 'update', 'index.php?id='. $tag->id, $tag->name . '->'. $tagnew->name); - } elseif ($tag->description != $tagnew->description) { + } elseif ($tag->description != $tagnew->description) { add_to_log($COURSE->id, 'tag', 'update', 'index.php?id='. $tag->id, $tag->name); } - + //updated related tags tag_set('tag', $tagnew->id, explode(',', trim($tagnew->relatedtags))); //print_object($tagnew); die(); - + redirect($CFG->wwwroot.'/tag/index.php?tag='.rawurlencode($tag->name)); // must use $tag here, as the name isn't in the edit form } } @@ -135,5 +135,3 @@ if (ajaxenabled()) { $PAGE->requires->js_function_call('init_tag_autocomplete')->on_dom_ready(); } echo $OUTPUT->footer(); - -?> diff --git a/tag/edit_form.php b/tag/edit_form.php index 8e781a580d..67396f6071 100644 --- a/tag/edit_form.php +++ b/tag/edit_form.php @@ -16,7 +16,7 @@ class tag_edit_form extends moodleform { $systemcontext = get_context_instance(CONTEXT_SYSTEM); if (has_capability('moodle/tag:manage', $systemcontext)) { - $mform->addElement('text', 'rawname', get_string('name', 'tag'), + $mform->addElement('text', 'rawname', get_string('name', 'tag'), 'maxlength="'.TAG_MAX_LENGTH.'" size="'.TAG_MAX_LENGTH.'"'); } @@ -25,7 +25,7 @@ class tag_edit_form extends moodleform { $mform->addElement('format', 'descriptionformat', get_string('format')); if (has_capability('moodle/tag:manage', $systemcontext)) { - $mform->addElement('checkbox', 'tagtype', get_string('officialtag', 'tag')); + $mform->addElement('checkbox', 'tagtype', get_string('officialtag', 'tag')); } $mform->addElement('html', '
'); @@ -39,5 +39,3 @@ class tag_edit_form extends moodleform { } } - -?> diff --git a/tag/index.php b/tag/index.php index 9cf65f84c0..020428c43c 100644 --- a/tag/index.php +++ b/tag/index.php @@ -1,4 +1,4 @@ - 0) { } echo $OUTPUT->footer(); -?> diff --git a/tag/lib.php b/tag/lib.php index 9e9b2fffed..b2e7003e4a 100644 --- a/tag/lib.php +++ b/tag/lib.php @@ -1,4 +1,4 @@ -execute("UPDATE {tag} SET flag = 0, timemodified = ? WHERE id IN ($tagids)", array($timemodified)); } - -?> diff --git a/tag/locallib.php b/tag/locallib.php index f7892c741b..9107731a20 100644 --- a/tag/locallib.php +++ b/tag/locallib.php @@ -1,4 +1,4 @@ - diff --git a/tag/manage.php b/tag/manage.php index d909966f45..1c2cf71f99 100644 --- a/tag/manage.php +++ b/tag/manage.php @@ -1,4 +1,4 @@ -libdir.'/tablelib.php'); @@ -53,7 +53,7 @@ switch($action) { if (!data_submitted() or !confirm_sesskey()) { break; } - + $str_tagschecked = implode(', ', tag_get_name($tagschecked)); tag_delete($tagschecked); $notice = $str_tagschecked.' -- '.get_string('deleted','tag'); @@ -96,7 +96,7 @@ switch($action) { if (!data_submitted() or !confirm_sesskey()) { break; } - + $tags_names_changed = array(); foreach ($tagschecked as $tag_id) { if ($newnames[$tag_id] != '') { @@ -276,5 +276,3 @@ if ($perpage == SHOW_ALL_PAGE_SIZE) { echo '
'; echo $OUTPUT->footer(); - -?> diff --git a/tag/search.php b/tag/search.php index 047e980cc6..3d883cd6c0 100644 --- a/tag/search.php +++ b/tag/search.php @@ -53,5 +53,3 @@ tag_print_cloud(150); echo $OUTPUT->box_end(); echo $OUTPUT->footer(); - -?> diff --git a/tag/tag_autocomplete.php b/tag/tag_autocomplete.php index f3f24d1cab..ef87e09d0e 100644 --- a/tag/tag_autocomplete.php +++ b/tag/tag_autocomplete.php @@ -16,5 +16,3 @@ if ($similar_tags = tag_autocomplete($query)) { echo $tag->name . "\t" . tag_display_name($tag) . "\n"; } } - -?> diff --git a/tag/user.php b/tag/user.php index df1722f480..20d21b20e3 100644 --- a/tag/user.php +++ b/tag/user.php @@ -1,4 +1,4 @@ -usetags)) { @@ -26,8 +26,8 @@ switch ($action) { case 'addinterest': if (empty($tag) && $id) { // for backward-compatibility (people saving bookmarks, mostly..) $tag = tag_get_name($id); - } - + } + tag_set_add('user', $USER->id, $tag); redirect($CFG->wwwroot.'/tag/index.php?tag='. rawurlencode($tag)); @@ -36,7 +36,7 @@ switch ($action) { case 'removeinterest': if (empty($tag) && $id) { // for backward-compatibility (people saving bookmarks, mostly..) $tag = tag_get_name($id); - } + } tag_set_delete('user', $USER->id, $tag); @@ -44,9 +44,9 @@ switch ($action) { break; case 'flaginappropriate': - + tag_set_flag(tag_get_id($tag)); - + redirect($CFG->wwwroot.'/tag/index.php?tag='. rawurlencode($tag), get_string('responsiblewillbenotified', 'tag')); break; @@ -54,5 +54,3 @@ switch ($action) { print_error('unknowaction'); break; } - -?> diff --git a/userpix/index.php b/userpix/index.php index 50ac819ed1..a842afba98 100644 --- a/userpix/index.php +++ b/userpix/index.php @@ -38,5 +38,3 @@ } echo $OUTPUT->footer(); - -?> diff --git a/userpix/upgrade.php b/userpix/upgrade.php index b0ba57b8a4..2e53f8eec4 100644 --- a/userpix/upgrade.php +++ b/userpix/upgrade.php @@ -35,5 +35,3 @@ } echo $OUTPUT->footer(); - -?>