print_user_picture($user->id, $course->id, $user->picture);
echo '</td>';
- echo '<td class="entryheader">';
+ echo '<th class="entryheader">';
echo '<span class="concept">';
glossary_print_entry_concept($entry);
- echo '</span><br />';
+ echo '</span>';
$fullname = fullname($user);
$by->name = '<a href="'.$CFG->wwwroot.'/user/view.php?id='.$user->id.'&course='.$course->id.'">'.$fullname.'</a>';
$by->date = userdate($entry->timemodified);
echo '<span class="author">'.get_string('bynameondate', 'forum', $by).'</span>';
- echo '</td>';
+ echo '</th>';
echo '<td class="entryapproval">';
glossary_print_entry_approval($cm, $entry, $mode);
echo '<table class="glossarypost faq" cellspacing="0">';
echo '<tr valign="top">';
- echo '<td class="entryheader">';
+ echo '<th class="entryheader">';
$entry->course = $course->id;
echo '<span class="concept">' . get_string('question','glossary') . ': ';
glossary_print_entry_concept($entry);
- echo '</span><br />';
+ echo '</span>';
echo '<span class="time">('.get_string('lastedited').': '.
userdate($entry->timemodified).')</span>';
- echo '</td>';
+ echo '</th>';
echo '<td class="entryattachment">';
glossary_print_entry_approval($cm, $entry, $mode);
//Default (old) print format used if custom function doesn't exist in format
function glossary_print_entry_default ($entry) {
- echo '<b>'. strip_tags($entry->concept) . ': </b>';
+ echo '<h3>'. strip_tags($entry->concept) . ': </h3>';
$definition = $entry->definition;
function glossary_print_entry_concept($entry) {
$options = new object();
$options->para = false;
- $text = format_text('<span class="nolink">' . $entry->concept . '</span>', FORMAT_MOODLE, $options);
+ $text = format_text('<h3 class="nolink">' . $entry->concept . '</h3>', FORMAT_MOODLE, $options);
if (!empty($entry->highlight)) {
$text = highlight($entry->highlight, $text);
}
$return = '<span class="commands">';
+ // Differentiate links for each entry.
+ $altsuffix = ': '.$entry->concept;
if (!$entry->approved) {
$output = true;
$return .= get_string('entryishidden','glossary');
if (has_capability('mod/glossary:comment', $context) and $glossary->allowcomments) {
$output = true;
- $return .= ' <a title="' . get_string('addcomment','glossary') . '" href="comment.php?action=add&eid='.$entry->id.'"><img src="comment.gif" class="iconsmall" alt="'.get_string('addcomment','glossary').'" /></a>';
+ $return .= ' <a title="' . get_string('addcomment','glossary') . '" href="comment.php?action=add&eid='.$entry->id.'"><img src="comment.gif" class="iconsmall" alt="'.get_string('addcomment','glossary').$altsuffix.'" /></a>';
}
$mainglossary = get_record('glossary','mainglossary',1,'course',$course->id);
if ( $mainglossary ) { // if there is a main glossary defined, allow to export the current entry
$output = true;
- $return .= ' <a title="'.get_string('exporttomainglossary','glossary') . '" href="exportentry.php?id='.$cm->id.'&entry='.$entry->id.'&mode='.$mode.'&hook='.$hook.'"><img src="export.gif" class="iconsmall" alt="'.get_string('exporttomainglossary','glossary').'" /></a>';
+ $return .= ' <a title="'.get_string('exporttomainglossary','glossary') . '" href="exportentry.php?id='.$cm->id.'&entry='.$entry->id.'&mode='.$mode.'&hook='.$hook.'"><img src="export.gif" class="iconsmall" alt="'.get_string('exporttomainglossary','glossary').$altsuffix.'" /></a>';
}
}
$output = true;
$return .= " <a title=\"" . get_string("delete") . "\" href=\"deleteentry.php?id=$cm->id&mode=delete&entry=$entry->id&prevmode=$mode&hook=$hook\"><img src=\"";
$return .= $icon;
- $return .= "\" class=\"iconsmall\" alt=\"" . get_string("delete") . "\" /></a> ";
+ $return .= "\" class=\"iconsmall\" alt=\"" . get_string("delete") .$altsuffix."\" /></a> ";
- $return .= " <a title=\"" . get_string("edit") . "\" href=\"edit.php?id=$cm->id&e=$entry->id&mode=$mode&hook=$hook\"><img src=\"$CFG->pixpath/t/edit.gif\" class=\"iconsmall\" alt=\"" . get_string("edit") . "\" /></a>";
+ $return .= " <a title=\"" . get_string("edit") . "\" href=\"edit.php?id=$cm->id&e=$entry->id&mode=$mode&hook=$hook\"><img src=\"$CFG->pixpath/t/edit.gif\" class=\"iconsmall\" alt=\"" . get_string("edit") .$altsuffix. "\" /></a>";
} elseif ( $importedentry ) {
$return .= " <font size=\"-1\">" . get_string("exportedentry","glossary") . "</font>";
}
} else {
$fullsearchchecked = '';
}
- echo '<input type="checkbox" name="fullsearch" value="1" '.$fullsearchchecked.' alt="'.$strsearchindefinition.'" />';
+ echo '<input type="checkbox" name="fullsearch" id="fullsearch" value="1" '.$fullsearchchecked.' />';
echo '<input type="hidden" name="mode" value="search" />';
echo '<input type="hidden" name="id" value="'.$cm->id.'" />';
- echo $strsearchindefinition;
+ echo '<label for="fullsearch">'.$strsearchindefinition.'</label>';
echo '</td></tr></table>';
echo '</form>';
print_user_picture($user->id, $course->id, $user->picture);
$pivottoshow = fullname($user, has_capability('moodle/site:viewfullnames', get_context_instance(CONTEXT_COURSE, $course->id)));
} else {
- echo '<td align="center">';
+ echo '<th >';
}
- echo "<strong> $pivottoshow</strong>" ;
- echo '</td></tr></table></div>';
+ print_heading($pivottoshow);
+ echo '</th></tr></table></div>';
}
}