MDL-11082 Improved groups upgrade performance 1.8x -> 1.9; thanks Eloy for telling...
[moodle-pu.git] / mod / glossary / formats / fullwithoutauthor / fullwithoutauthor_format.php
blobfad2ba4f37d3876aaba1ff6d301d8a815f6dfa42
1 <?php // $Id$
3 function glossary_show_entry_fullwithoutauthor($course, $cm, $glossary, $entry, $mode="", $hook="", $printicons=1, $ratings=NULL, $aliases=true) {
4 global $CFG, $USER;
7 $return = false;
8 if ($entry) {
9 echo '<table class="glossarypost fullwithoutauthor" cellspacing="0">';
10 echo '<tr valign="top">';
12 echo '<td class="entryheader">';
14 echo '<span class="concept">';
15 glossary_print_entry_concept($entry);
16 echo '</span><br />';
18 echo '<span class="time">('.get_string('lastedited').': '.
19 userdate($entry->timemodified).')</span>';
20 echo '</td>';
21 echo '<td class="entryattachment">';
23 glossary_print_entry_approval($cm, $entry, $mode);
24 glossary_print_entry_attachment($entry,'html','right');
25 echo '</td>';
27 echo '</tr>';
29 echo '<tr valign="top">';
30 echo '<td width="100%" colspan="2" class="entry">';
32 glossary_print_entry_definition($entry);
34 echo '</td></tr>';
35 echo '<tr valign="top"><td colspan="2" class="entrylowersection">';
36 $return = glossary_print_entry_lower_section($course, $cm, $glossary, $entry, $mode, $hook, $printicons, $ratings, $aliases);
38 echo ' ';
39 echo '</td></tr>';
40 echo "</table>\n";
41 } else {
42 echo '<center>';
43 print_string('noentry', 'glossary');
44 echo '</center>';
46 return $return;
49 function glossary_print_entry_fullwithoutauthor($course, $cm, $glossary, $entry, $mode="", $hook="", $printicons=1, $ratings=NULL) {
51 //The print view for this format is exactly the normal view, so we use it
53 //Take out autolinking in definitions un print view
54 $entry->definition = '<span class="nolink">'.$entry->definition.'</span>';
56 //Call to view function (without icons, ratings and aliases) and return its result
57 return glossary_show_entry_fullwithoutauthor($course, $cm, $glossary, $entry, $mode, $hook, false, false, false);