From 1a1a09d8f887daae5400f2206d6561d53db08d64 Mon Sep 17 00:00:00 2001 From: Damyon Wiese Date: Fri, 10 Mar 2017 10:37:29 +0800 Subject: [PATCH] MDL-58142 calendar: Add an obvious link to the help docs Part of MDL-58220 --- calendar/classes/export_form.php | 4 +++- calendar/export.php | 1 + lang/en/calendar.php | 1 + 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/calendar/classes/export_form.php b/calendar/classes/export_form.php index c7a782563d7..6789a8a68df 100644 --- a/calendar/classes/export_form.php +++ b/calendar/classes/export_form.php @@ -42,9 +42,11 @@ class core_calendar_export_form extends moodleform { * @throws coding_exception */ public function definition() { - global $CFG; + global $CFG, $OUTPUT; $mform = $this->_form; + $mform->addElement('html', '

' . $OUTPUT->doc_link('calendar/export', get_string('exporthelp', 'calendar'), true) . '

'); + $export = array(); $export[] = $mform->createElement('radio', 'exportevents', '', get_string('eventsall', 'calendar'), 'all'); $export[] = $mform->createElement('radio', 'exportevents', '', get_string('eventsrelatedtocourses', 'calendar'), 'courses'); diff --git a/calendar/export.php b/calendar/export.php index 979c89272b9..8c5d175be65 100644 --- a/calendar/export.php +++ b/calendar/export.php @@ -169,4 +169,5 @@ if ($action != 'advanced') { echo $calendarurl; echo $renderer->complete_layout(); + echo $OUTPUT->footer(); diff --git a/lang/en/calendar.php b/lang/en/calendar.php index 9782884e5f2..a24c0f32cb6 100644 --- a/lang/en/calendar.php +++ b/lang/en/calendar.php @@ -117,6 +117,7 @@ $string['eventsubscriptioneditwarning'] = 'This calendar event is part of a subs $string['expired'] = 'Expired'; $string['explain_site_timeformat'] = 'You can choose to see times in either 12 or 24 hour format for the whole site. If you choose "default", then the format will be automatically chosen according to the language you use in the site. This setting can be overridden by user preferences.'; $string['export'] = 'Export'; +$string['exporthelp'] = 'How do I subscribe to this calendar from a calendar application (Google/Outlook/Other)?'; $string['exportbutton'] = 'Export'; $string['exportcalendar'] = 'Export calendar'; $string['forcecalendartype'] = 'Force calendar';