]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-8360 - Currently can't bookmark admin searches, so disable the ability to bookmark
authorpoltawski <poltawski>
Wed, 14 Mar 2007 12:04:56 +0000 (12:04 +0000)
committerpoltawski <poltawski>
Wed, 14 Mar 2007 12:04:56 +0000 (12:04 +0000)
the search page

blocks/admin_bookmarks/block_admin_bookmarks.php

index ee427de847b8daf4cf72f35a1a2b72e64b46e2fd..fdbd61bd547fd6d34d9acf5f38641d9fd86571c2 100644 (file)
@@ -57,7 +57,10 @@ class block_admin_bookmarks extends block_base {
             $bookmarks = array();
         }
 
-        if (($section = (isset($PAGE->section) ? $PAGE->section : '')) && (in_array($section, $bookmarks))) {
+       if($PAGE->section == 'search'){
+         // the search page can't be properly bookmarked at present
+         $this->content->footer = '';
+       }elseif (($section = (isset($PAGE->section) ? $PAGE->section : '')) && (in_array($section, $bookmarks))) {
             $this->content->footer = '<a href="' . $CFG->wwwroot . '/blocks/admin_bookmarks/delete.php?section=' . $section . '&amp;sesskey='.sesskey().'">' . get_string('unbookmarkthispage','admin') . '</a>';
         } elseif ($section = (isset($PAGE->section) ? $PAGE->section : '')) {
             $this->content->footer = '<a href="' . $CFG->wwwroot . '/blocks/admin_bookmarks/create.php?section=' . $section . '&amp;sesskey='.sesskey().'">' . get_string('bookmarkthispage','admin') . '</a>';