MDL-21695 adding support for module help
authorPetr Skoda <skodak@moodle.org>
Tue, 13 Apr 2010 21:59:15 +0000 (21:59 +0000)
committerPetr Skoda <skodak@moodle.org>
Tue, 13 Apr 2010 21:59:15 +0000 (21:59 +0000)
course/modedit.php
mod/page/lang/en/page.php

index efc3260..2d8b976 100644 (file)
             require($CFG->dirroot.'/'.$CFG->admin.'/roles/tabs.php');
         }
 
-        echo $OUTPUT->heading_with_help($pageheading, 'mods', $module->name, 'icon');
+        if (get_string_manager()->string_exists('modulename_hlp', $module->name)) {
+            echo $OUTPUT->heading_with_help($pageheading, 'modulename', $module->name, 'icon');
+        } else {
+            echo $OUTPUT->heading_with_help($pageheading, '', '', 'icon');
+        }
 
         $mform->display();
 
index d4b95fc..d4f5143 100644 (file)
@@ -35,6 +35,7 @@ $string['legacyfiles'] = 'Migration of old course file';
 $string['legacyfilesactive'] = 'Active';
 $string['legacyfilesdone'] = 'Finished';
 $string['modulename'] = 'Page';
+$string['modulename_hlp'] = 'Page module allows teachers to edit a page directly in a course.';
 $string['modulenameplural'] = 'Pages';
 $string['optionsheader'] = 'Options';
 $string['pageadministration'] = 'Page administration';