Skip to content

Commit

Permalink
"COMMENT MDL-19118 improve nonjs comment ui link"
Browse files Browse the repository at this point in the history
  • Loading branch information
Dongsheng Cai committed Aug 2, 2010
1 parent f31daba commit b667ba0
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 1 deletion.
6 changes: 5 additions & 1 deletion comment/lib.php
Expand Up @@ -315,6 +315,7 @@ public function output($return = true) {

$strsubmit = get_string('savecomment');
$strcancel = get_string('cancel');
$strshowcomments = get_string('showcommentsnonjs');
$sesskey = sesskey();
$html = '';
// print html template
Expand All @@ -329,7 +330,10 @@ public function output($return = true) {
$icon = $OUTPUT->pix_url('t/collapsed');
$html .= <<<EOD
<div class="mdl-left">
<a id="comment-link-{$this->cid}" href="{$this->link}">
<noscript>
<a href="{$this->link}">{$strshowcomments}</a>
</noscript>
<a id="comment-link-{$this->cid}" class="comment-link" href="#">
<img id="comment-img-{$this->cid}" src="$icon" alt="{$this->linktext}" title="{$this->linktext}" />
<span id="comment-link-text-{$this->cid}">{$this->linktext} {$this->count}</span>
</a>
Expand Down
1 change: 1 addition & 0 deletions lang/en/moodle.php
Expand Up @@ -1480,6 +1480,7 @@
$string['showallweeks'] = 'Show all weeks';
$string['showblockcourse'] = 'Show list of courses containing block';
$string['showcomments'] = 'Show/hide comments';
$string['showcommentsnonjs'] = 'Show comments';
$string['showgrades'] = 'Show gradebook to students';
$string['showgrades_help'] = 'Many activities in the course allow grades to be set. This setting determines whether a student can view a list of all their grades for the course via a grades link in the course administration block.';
$string['showlistofcourses'] = 'Show list of courses';
Expand Down
2 changes: 2 additions & 0 deletions theme/base/style/core.css
Expand Up @@ -332,6 +332,8 @@ table.mod_index {width:100%;}
.comment-delete-confirm {background: #eee; padding: 2px; width: 5em;text-align:center;}
.comment-container {float:left;margin: 4px;}
.comment-report-selectall{display:none}
.comment-link {display:none}
.jsenabled .comment-link {display:block}
.jsenabled .comment-report-selectall{display:inline}

/**
Expand Down

0 comments on commit b667ba0

Please sign in to comment.