Accessibility: (strict HTML) remove unnecessary width/height attributes on <img> (OU-Bugz: 697)
This commit is contained in:
@@ -34,39 +34,39 @@ class block_admin extends block_list {
|
||||
|
||||
if (isadmin()) {
|
||||
$this->content->items[] = '<a href="'.$CFG->wwwroot.'/'.$CFG->admin.'/configure.php">'.get_string('configuration').'</a>';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/admin.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/admin.gif" alt="" />';
|
||||
|
||||
$this->content->items[] = '<a href="'.$CFG->wwwroot.'/'.$CFG->admin.'/users.php">'.get_string('users').'</a>';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/users.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/users.gif" alt="" />';
|
||||
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/backup/backup.php?id='.SITEID.'">'.get_string('backup').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/backup.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/backup.gif" alt="" />';
|
||||
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/files/index.php?id='.SITEID.'&wdir=/backupdata">'.get_string('restore').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/restore.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/restore.gif" alt="" />';
|
||||
}
|
||||
|
||||
if (iscreator()) {
|
||||
$this->content->items[] = '<a href="'.$CFG->wwwroot.'/course/index.php?edit=on&sesskey='.sesskey().'">'.get_string('courses').'</a>';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/course.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/course.gif" alt="" />';
|
||||
}
|
||||
|
||||
if (isadmin()) {
|
||||
$this->content->items[] = '<a href="'.$CFG->wwwroot.'/course/log.php?id='.SITEID.'">'.get_string('logs').'</a>';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/log.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/log.gif" alt="" />';
|
||||
|
||||
|
||||
if (!empty($CFG->enablestats)) {
|
||||
$this->content->items[] = '<a href="'.$CFG->wwwroot.'/course/stats.php?course='.SITEID.'">'.get_string('stats').'</a>';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/stats.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/stats.gif" alt="" />';
|
||||
}
|
||||
|
||||
$this->content->items[] = '<a href="'.$CFG->wwwroot.'/files/index.php?id='.SITEID.'">'.get_string('sitefiles').'</a>';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/files.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/files.gif" alt="" />';
|
||||
|
||||
if (file_exists($CFG->dirroot.'/'.$CFG->admin.'/'.$CFG->dbtype)) {
|
||||
$this->content->items[] = '<a href="'.$CFG->wwwroot.'/'.$CFG->admin.'/'.$CFG->dbtype.'/frame.php">'.get_string('managedatabase').'</a>';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/db.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/db.gif" alt="" />';
|
||||
}
|
||||
|
||||
if ($CFG->enrol == 'authorize') {
|
||||
@@ -76,7 +76,7 @@ class block_admin extends block_list {
|
||||
$paymenturl .= '<a href="'.$CFG->wwwroot.'/enrol/authorize/index.php?status='.AN_STATUS_AUTH.'">'.get_string('paymentpending', 'moodle', $cnt).'</a>';
|
||||
}
|
||||
$this->content->items[] = $paymenturl;
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/payment.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/payment.gif" alt="" />';
|
||||
}
|
||||
|
||||
$this->content->footer = '<a href="'.$CFG->wwwroot.'/'.$CFG->admin.'/">'.get_string('admin').'...</a>';
|
||||
@@ -99,7 +99,7 @@ class block_admin extends block_list {
|
||||
$isteacheredit = isteacheredit($this->instance->pageid);
|
||||
|
||||
if ($isteacheredit) {
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/edit.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/edit.gif" alt="" />';
|
||||
if (isediting($this->instance->pageid)) {
|
||||
$this->content->items[]='<a href="view.php?id='.$this->instance->pageid.'&edit=off&sesskey='.sesskey().'">'.get_string('turneditingoff').'</a>';
|
||||
} else {
|
||||
@@ -107,7 +107,7 @@ class block_admin extends block_list {
|
||||
}
|
||||
|
||||
$this->content->items[]='<a href="edit.php?id='.$this->instance->pageid.'">'.get_string('settings').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/settings.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/settings.gif" alt="" />';
|
||||
|
||||
|
||||
$fullname = fullname($USER, true);
|
||||
@@ -119,7 +119,7 @@ class block_admin extends block_list {
|
||||
} else {
|
||||
$this->content->items[]= $editmyprofile;
|
||||
}
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" alt="" />';
|
||||
|
||||
|
||||
if (iscreator() || !empty($CFG->teacherassignteachers)) {
|
||||
@@ -127,7 +127,7 @@ class block_admin extends block_list {
|
||||
$course->teachers = get_string('defaultcourseteachers');
|
||||
}
|
||||
$this->content->items[]='<a href="teacher.php?id='.$this->instance->pageid.'">'.$course->teachers.'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/users.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/users.gif" alt="" />';
|
||||
}
|
||||
|
||||
if (!$course->students) {
|
||||
@@ -135,46 +135,46 @@ class block_admin extends block_list {
|
||||
}
|
||||
if (!$course->metacourse) {
|
||||
$this->content->items[]='<a href="student.php?id='.$this->instance->pageid.'">'.$course->students.'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/users.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/users.gif" alt="" />';
|
||||
} else {
|
||||
$strchildcourses = get_string('childcourses');
|
||||
$this->content->items[]='<a href="importstudents.php?id='.$this->instance->pageid.'">'.$strchildcourses.'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/course.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/course.gif" alt="" />';
|
||||
}
|
||||
if ($course->groupmode || !$course->groupmodeforce) {
|
||||
$strgroups = get_string('groups');
|
||||
$this->content->items[]='<a title="'.$strgroups.'" href="'.$CFG->wwwroot.'/course/groups.php?id='.$this->instance->pageid.'">'.$strgroups.'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/group.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/group.gif" alt="" />';
|
||||
}
|
||||
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/backup/backup.php?id='.$this->instance->pageid.'">'.get_string('backup').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/backup.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/backup.gif" alt="" />';
|
||||
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/files/index.php?id='.$this->instance->pageid.'&wdir=/backupdata">'.get_string('restore').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/restore.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/restore.gif" alt="" />';
|
||||
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/course/import.php?id='.$this->instance->pageid.'">'.get_string('import').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/restore.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/restore.gif" alt="" />';
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/course/report.php?id='.$this->instance->pageid.'">'.get_string('reports').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/stats.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/stats.gif" alt="" />';
|
||||
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/question/edit.php?courseid='.$this->instance->pageid.'&clean=true">'.get_string('questions', 'quiz').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/questions.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/questions.gif" alt="" />';
|
||||
|
||||
$this->content->items[]='<a href="scales.php?id='.$this->instance->pageid.'">'.get_string('scales').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/scales.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/scales.gif" alt="" />';
|
||||
|
||||
}
|
||||
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/grade/index.php?id='.$this->instance->pageid.'">'.get_string('grades').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/grades.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/grades.gif" alt="" />';
|
||||
|
||||
$this->content->items[]='<a href="log.php?id='.$this->instance->pageid.'">'.get_string('logs').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/log.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/log.gif" alt="" />';
|
||||
|
||||
if ($isteacheredit) {
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/files/index.php?id='.$this->instance->pageid.'">'.get_string('files').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/files.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/files.gif" alt="" />';
|
||||
}
|
||||
|
||||
if ($course->enrol == 'authorize' || (empty($course->enrol) && $CFG->enrol == 'authorize')) {
|
||||
@@ -184,26 +184,26 @@ class block_admin extends block_list {
|
||||
$paymenturl .= '<a href="'.$CFG->wwwroot.'/enrol/authorize/index.php?status='.AN_STATUS_AUTH.'&course='.$course->id.'">'.get_string('paymentpending', 'moodle', $cnt).'</a>';
|
||||
}
|
||||
$this->content->items[] = $paymenturl;
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/payment.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[] = '<img src="'.$CFG->pixpath.'/i/payment.gif" alt="" />';
|
||||
}
|
||||
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/doc/view.php?id='.$this->instance->pageid.'&file=teacher.html">'.get_string('help').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->modpixpath.'/resource/icon.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->modpixpath.'/resource/icon.gif" alt="" />';
|
||||
|
||||
if ($teacherforum = forum_get_course_forum($this->instance->pageid, 'teacher')) {
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/mod/forum/view.php?f='.$teacherforum->id.'">'.get_string('nameteacher', 'forum').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->modpixpath.'/forum/icon.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->modpixpath.'/forum/icon.gif" alt="" />';
|
||||
}
|
||||
|
||||
} else if (!isguest()) { // Students menu
|
||||
|
||||
if ($course->showgrades) {
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/grade/index.php?id='.$this->instance->pageid.'">'.get_string('grades').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/grades.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/grades.gif" alt="" />';
|
||||
}
|
||||
if ($course->showreports) {
|
||||
$this->content->items[]='<a href="user.php?id='.$this->instance->pageid.'&user='.$USER->id.'">'.get_string('activityreport').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/report.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/report.gif" alt="" />';
|
||||
}
|
||||
|
||||
$fullname = fullname($USER, true);
|
||||
@@ -216,18 +216,18 @@ class block_admin extends block_list {
|
||||
} else {
|
||||
$this->content->items[]= $editmyprofile;
|
||||
}
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" alt="" />';
|
||||
|
||||
if (is_internal_auth() && !is_restricted_user($USER->username)) {
|
||||
$this->content->items[]='<a href="'.$CFG->wwwroot.'/login/change_password.php?id='.$this->instance->pageid.'">'.get_string('changepassword').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" alt="" />';
|
||||
} else if ($CFG->changepassword && !is_restricted_user($USER->username)) {
|
||||
$this->content->items[]='<a href="'.$CFG->changepassword.'">'.get_string('changepassword').'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" alt="" />';
|
||||
}
|
||||
if ($CFG->allowunenroll && !$course->metacourse) {
|
||||
$this->content->items[]='<a href="unenrol.php?id='.$this->instance->pageid.'">'.get_string('unenrolme', '', $course->shortname).'</a>';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" height="16" width="16" alt="" />';
|
||||
$this->content->icons[]='<img src="'.$CFG->pixpath.'/i/user.gif" alt="" />';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -431,6 +431,11 @@ a.skip-block, .skip-block {
|
||||
font-size:1px;
|
||||
}
|
||||
|
||||
.sideblock .icon img {
|
||||
width:16px;
|
||||
height:16px;
|
||||
}
|
||||
|
||||
ul.list, ul.list li {
|
||||
list-style-type:none;
|
||||
padding:0%;
|
||||
|
||||
Reference in New Issue
Block a user