From 4ce274696fd1d112bcb2cb146fb556f825c299d2 Mon Sep 17 00:00:00 2001 From: Andrew Davis Date: Sun, 18 Jul 2010 08:28:09 +0000 Subject: [PATCH] glossary MDL-23360 fixed some display problems with the glossary --- .../formats/dictionary/dictionary_format.php | 2 +- mod/glossary/lib.php | 7 +------ mod/glossary/styles.css | 9 ++++++--- mod/glossary/view.php | 17 ----------------- theme/standard/style/modules.css | 4 ++-- 5 files changed, 10 insertions(+), 29 deletions(-) diff --git a/mod/glossary/formats/dictionary/dictionary_format.php b/mod/glossary/formats/dictionary/dictionary_format.php index 37cc6eda6f5..362c5ce09fa 100644 --- a/mod/glossary/formats/dictionary/dictionary_format.php +++ b/mod/glossary/formats/dictionary/dictionary_format.php @@ -11,7 +11,7 @@ function glossary_show_entry_dictionary($course, $cm, $glossary, $entry, $mode=' glossary_print_entry_attachment($entry, $cm, 'html', 'right'); echo '
'; glossary_print_entry_concept($entry); - echo ':
'; + echo ' '; glossary_print_entry_definition($entry, $glossary, $cm); echo ''; echo ''; diff --git a/mod/glossary/lib.php b/mod/glossary/lib.php index 920a6e0062c..116d948ea2c 100644 --- a/mod/glossary/lib.php +++ b/mod/glossary/lib.php @@ -1648,18 +1648,13 @@ function glossary_print_alphabet_links($cm, $glossary, $mode, $hook, $sortkey, $ global $CFG; if ( $glossary->showalphabet) { $alphabet = explode(",", get_string('alphabet', 'langconfig')); - $letters_by_line = 14; for ($i = 0; $i < count($alphabet); $i++) { if ( $hook == $alphabet[$i] and $hook) { echo "$alphabet[$i]"; } else { echo "wwwroot/mod/glossary/view.php?id=$cm->id&mode=$mode&hook=".urlencode($alphabet[$i])."&sortkey=$sortkey&sortorder=$sortorder\">$alphabet[$i]"; } - if ((int) ($i % $letters_by_line) != 0 or $i == 0) { - echo ' | '; - } else { - echo '
'; - } + echo ' | '; } } } diff --git a/mod/glossary/styles.css b/mod/glossary/styles.css index a66c50ccba5..47427becb47 100644 --- a/mod/glossary/styles.css +++ b/mod/glossary/styles.css @@ -1,5 +1,5 @@ /** General Styles **/ -.path-mod-glossary .glossarypost {border-collapse:separate;margin:5px auto;text-align: left;} +.path-mod-glossary .glossarypost {width: 95%;border-collapse:separate;margin:0px auto;text-align: left;} .path-mod-glossary .glossarypost.entrylist {border-width:0px;} .path-mod-glossary .glossarypost.continuous .concept {display: inline;} .path-mod-glossary .glossarypost .commands {width: 200px;white-space: nowrap;} @@ -16,9 +16,12 @@ .path-mod-glossary table.glossarypopup {width: 95%;} .path-mod-glossary .entrybox, /** Used in tabs.php **/ .path-mod-glossary table.glossaryapproval, -.path-mod-glossary .glossarypost .entrylowersection table{width: 100%;} +.path-mod-glossary .glossarypost .entrylowersection table{width: 100%;margin-bottom:0em;} /** Page specific styles **/ #page-mod-glossary-view .glossarycontrol {float: right;text-align:right;white-space: nowrap;margin: 5px 0;} #page-mod-glossary-view table.glossarycategoryheader, -#page-mod-glossary-import table.glossaryimportexport {margin-left:auto;margin-right:auto;} \ No newline at end of file +#page-mod-glossary-import table.glossaryimportexport {margin-left:auto;margin-right:auto;} + +#page-mod-glossary-view table.glossarycategoryheader {margin-bottom:0em;} +#page-mod-glossary-view table.glossarycategoryheader th {padding:0px;} \ No newline at end of file diff --git a/mod/glossary/view.php b/mod/glossary/view.php index 76758482025..5bf8cca16db 100644 --- a/mod/glossary/view.php +++ b/mod/glossary/view.php @@ -300,23 +300,6 @@ if ($showcommonelements) { echo '
'; echo $availableoptions; -/// If rss are activated at site and glossary level and this glossary has rss defined, show link - /*if (!empty($CFG->enablerssfeeds) && !empty($CFG->glossary_enablerssfeeds) - && $glossary->rsstype && $glossary->rssarticles) { - - $tooltiptext = get_string("rsssubscriberss",'glossary',format_string($glossary->name,true)); - if (!isloggedin()) { - $userid = 0; - } else { - $userid = $USER->id; - } -// print_box_start('rsslink'); - echo ''; - rss_print_link($context->id, $userid, "glossary", $glossary->id, $tooltiptext); - echo ''; -// print_box_end(); - }*/ - /// The print icon if ( $showcommonelements and $mode != 'search') { if (has_capability('mod/glossary:manageentries', $context) or $glossary->allowprintview) { diff --git a/theme/standard/style/modules.css b/theme/standard/style/modules.css index c27964109c5..3efafb543e2 100644 --- a/theme/standard/style/modules.css +++ b/theme/standard/style/modules.css @@ -110,7 +110,7 @@ table.mod_index {width:90%;margin:1em auto;} #page-mod-forum-view .highlight2 {color:#AA0000;} /** Glossary **/ -.path-mod-glossary .glossarypost {width: 95%;border:1px solid #DDD;} +.path-mod-glossary .glossarypost {border:1px solid #DDD;} .path-mod-glossary .glossarypost .entry {padding: 3px;} .path-mod-glossary .glossarypost .concept h3 {font-size: 1em;margin: 0;font-weight: normal;text-align: left;} .path-mod-glossary .glossarypost .entryheader {font-weight: normal;text-align: left;} @@ -133,7 +133,7 @@ table.mod_index {width:90%;margin:1em auto;} .path-mod-glossary .entrybox {border-width: 0px 1px 1px 1px;border-style: solid;border-color: #BBB;} .path-mod-glossary .entrybox hr {border-left:none;border-right:none;} #page-mod-glossary-report table tr.teacher {background: #F0F0F0;} -#page-mod-glossary-view table.glossarycategoryheader {width: 95%;background-color: #DDD;} +#page-mod-glossary-view table.glossarycategoryheader {background-color: #DDD;} #page-mod-glossary-view table.glossarycategoryheader h2 {font-size: 1em;margin: 0;} /** Lesson **/