Skip to content

Commit

Permalink
Merged MDL-13640 to move "Manage tags" link
Browse files Browse the repository at this point in the history
  • Loading branch information
moodler committed Feb 25, 2008
1 parent 3627b0e commit 03ce38c
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 2 deletions.
8 changes: 7 additions & 1 deletion tag/index.php
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,15 @@
$USER->editing = $edit;
}

$systemcontext = get_context_instance(CONTEXT_SYSTEM);

$PAGE->print_header();

// Manage all tags links
if (has_capability('moodle/tag:manage', $systemcontext)) {
echo '<div class="managelink"><a href="'. $CFG->wwwroot .'/tag/manage.php">'. get_string('managetags', 'tag') .'</a></div>' ;
}

echo '<table border="0" cellpadding="3" cellspacing="0" width="100%" id="layout-table">';
echo '<tr valign="top">';

Expand All @@ -57,7 +64,6 @@

$tagname = tag_display_name($tag);

$systemcontext = get_context_instance(CONTEXT_SYSTEM);
if ($tag->flag > 0 && has_capability('moodle/tag:manage', $systemcontext)) {
$tagname = '<span class="flagged-tag">' . rawurlencode($tagname) . '</span>';
}
Expand Down
5 changes: 4 additions & 1 deletion tag/search.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,10 @@
$manage_link = "<a href=\"{$CFG->wwwroot}/tag/manage.php\">" . get_string('managetags', 'tag') . "</a>" ;
}

print_header_simple(get_string('tags', 'tag'), '', $navigation, '', '', '', $manage_link);
print_header_simple(get_string('tags', 'tag'), '', $navigation);

echo '<div class="managelink"><a href="'. $CFG->wwwroot .'/tag/manage.php">'. get_string('managetags', 'tag') .'</a></div>' ;

print_heading(get_string('searchtags', 'tag'), '', 2);

tag_print_search_box();
Expand Down
5 changes: 5 additions & 0 deletions theme/standard/styles_layout.css
Original file line number Diff line number Diff line change
Expand Up @@ -2847,6 +2847,11 @@ div#tag-user-table {
display:block;
}

body.tag .managelink {
text-align:right;
padding:10px;
}

/* small css hack for firefox*/
div#tag-user-table:after{
content:".";
Expand Down

0 comments on commit 03ce38c

Please sign in to comment.