Permalink
Browse files

[MDL-22449]

Adding some help to wiki
  • Loading branch information...
1 parent d543cc3 commit 9e25c7b48004c7b8a6f487c1582fbb97098c4b82 Jordi Piguillem committed Sep 9, 2010
Showing with 18 additions and 2 deletions.
  1. +4 −0 mod/wiki/create_form.php
  2. +3 −0 mod/wiki/edit_form.php
  3. +11 −2 mod/wiki/lang/en/wiki.php
View
@@ -44,6 +44,8 @@ protected function definition() {
}
$mform->addElement('text', 'pagetitle', get_string('newpagetitle', 'wiki'), $textoptions);
+ $mform->addElement('static', 'format', get_string('format', 'wiki'));
+ $mform->addHelpButton('format', 'format', 'wiki');
foreach ($formats as $format) {
if ($format == $defaultformat) {
$attr = array('checked'=>'checked');
@@ -52,7 +54,9 @@ protected function definition() {
} else {
$attr = array();
}
+
$mform->addElement('radio', 'pageformat', '', get_string('format'.$format, 'wiki'), $format, $attr);
+
}
//hiddens
View
@@ -57,8 +57,11 @@ protected function definition() {
if ($format != 'html') {
$mform->addElement('wikieditor', 'newcontent', get_string('content'), array('cols' => 50, 'rows' => 20, 'wiki_format' => $format));
+ $mform->addHelpButton('newcontent', 'format'.$format, 'wiki');
} else {
$mform->addElement('editor', 'newcontent_editor', get_string('content'), null, page_wiki_edit::$attachmentoptions);
+ $mform->addHelpButton('newcontent_editor', 'formathtml', 'wiki');
+
}
//hiddens
View
@@ -36,7 +36,7 @@
* HTML - The HTML editor is available
* Creole - A common wiki markup language for which a small edit toolbar is available
-* Nwiki - The markup language used in the contributed Nwiki module';
+* Nwiki - Mediawiki-like markup language used in the contributed Nwiki module';
$string['deletecomment'] = 'Deleting comment';
$string['deleteupload'] = 'Delete';
$string['deletedbegins'] = 'Deleted begins';
@@ -54,9 +54,18 @@
$string['firstpagetitle_help'] = 'Title of the first page of the wiki.';
$string['forceformat'] = 'Force format';
$string['forceformat_help'] = 'If the format is forced (checkbox ticked), there is no option to choose a format when editing a wiki page.';
+$string['format'] = 'Format';
+$string['format_help'] = 'Format used when editing wiki pages.
+
+* HTML - The HTML editor is available
+* Creole - A common wiki markup language for which a small edit toolbar is available
+* Nwiki - Mediawiki-like markup language used in the contributed Nwiki module';
$string['formathtml'] = 'HTML Format';
+$string['formathtml_help'] = '<a href="http://docs.moodle.org/en/HTML_format">HTML Format</a>';
$string['formatcreole'] = 'Creole Format';
-$string['formatnwiki'] = 'NWIKI Format';
+$string['formatcreole_help'] = '<a href="http://docs.moodle.org/en/Creole_format">Creole Format</a>';
+$string['formatnwiki'] = 'NWiki Format';
+$string['formatnwiki_help'] = '<a href="http://docs.moodle.org/en/NWiki_format">NWiki Format</a>';
$string['history'] = 'History';
$string['html'] = 'HTML';
$string['insertcomment'] = 'Insert comment';

0 comments on commit 9e25c7b

Please sign in to comment.