@@ -41,7 +41,7 @@ |
||
41 | 41 | */ |
42 | 42 | protected function init($crud = 'r', $edulevel = self::LEVEL_OTHER) { |
43 | 43 | parent::init($crud, $edulevel); |
44 | - $this->description = "The user with id '##userid' has imported a recording with id ". |
|
44 | + $this->description = "The user with id '##userid' has imported a recording with id " . |
|
45 | 45 | "'##other' in the course id '##courseid'."; |
46 | 46 | } |
47 | 47 |
@@ -41,8 +41,8 @@ |
||
41 | 41 | */ |
42 | 42 | protected function init($crud = 'r', $edulevel = self::LEVEL_PARTICIPATING) { |
43 | 43 | parent::init($crud, $edulevel); |
44 | - $this->description = "The user with id '##userid' has joined a bigbluebutton meeting for ". |
|
45 | - "the bigbluebuttonbn activity with id '##objectid' for the course id ". |
|
44 | + $this->description = "The user with id '##userid' has joined a bigbluebutton meeting for " . |
|
45 | + "the bigbluebuttonbn activity with id '##objectid' for the course id " . |
|
46 | 46 | "'##courseid'."; |
47 | 47 | } |
48 | 48 |
@@ -41,7 +41,7 @@ |
||
41 | 41 | */ |
42 | 42 | protected function init($crud = 'r', $edulevel = self::LEVEL_OTHER) { |
43 | 43 | parent::init($crud, $edulevel); |
44 | - $this->description = "The user with id '##userid' has protected a recording with id ". |
|
44 | + $this->description = "The user with id '##userid' has protected a recording with id " . |
|
45 | 45 | "'##other' in the course id '##courseid'."; |
46 | 46 | } |
47 | 47 |
@@ -41,7 +41,7 @@ |
||
41 | 41 | */ |
42 | 42 | protected function init($crud = 'r', $edulevel = self::LEVEL_OTHER) { |
43 | 43 | parent::init($crud, $edulevel); |
44 | - $this->description = "The user with id '##userid' has viewed a recording with id ". |
|
44 | + $this->description = "The user with id '##userid' has viewed a recording with id " . |
|
45 | 45 | "'##other' from the course id '##courseid'."; |
46 | 46 | } |
47 | 47 |
@@ -209,8 +209,8 @@ discard block |
||
209 | 209 | $this->bigbluebuttonbn_mform_add_element($mform, $field['type'], $field['name'], $field['data_type'], |
210 | 210 | $field['description_key'], 0, ['maxlength' => 4, 'size' => 6], |
211 | 211 | ['message' => get_string('mod_form_field_voicebridge_format_error', 'bigbluebuttonbn'), |
212 | - 'type' => 'numeric', 'rule' => '####', 'validator' => 'server'] |
|
213 | - ); |
|
212 | + 'type' => 'numeric', 'rule' => '####', 'validator' => 'server'] |
|
213 | + ); |
|
214 | 214 | } else { |
215 | 215 | $this->bigbluebuttonbn_mform_add_element($mform, $field['type'], $field['name'], $field['data_type'], |
216 | 216 | $field['description_key'], 0, ['maxlength' => 4, 'size' => 6]); |
@@ -248,7 +248,7 @@ discard block |
||
248 | 248 | */ |
249 | 249 | private function bigbluebuttonbn_mform_add_block_room_recordings(&$mform, $cfg) { |
250 | 250 | $field = ['type' => 'hidden', 'name' => 'recordings_html', 'data_type' => PARAM_INT, |
251 | - 'description_key' => null]; |
|
251 | + 'description_key' => null]; |
|
252 | 252 | if ($cfg['recordings_html_editable']) { |
253 | 253 | $field['type'] = 'checkbox'; |
254 | 254 | $field['description_key'] = 'mod_form_field_recordings_html'; |
@@ -256,7 +256,7 @@ discard block |
||
256 | 256 | $this->bigbluebuttonbn_mform_add_element($mform, $field['type'], $field['name'], $field['data_type'], |
257 | 257 | $field['description_key'], $cfg['recordings_html_default']); |
258 | 258 | $field = ['type' => 'hidden', 'name' => 'recordings_deleted', 'data_type' => PARAM_INT, |
259 | - 'description_key' => null]; |
|
259 | + 'description_key' => null]; |
|
260 | 260 | if ($cfg['recordings_deleted_editable']) { |
261 | 261 | $field['type'] = 'checkbox'; |
262 | 262 | $field['description_key'] = 'mod_form_field_recordings_deleted'; |
@@ -264,7 +264,7 @@ discard block |
||
264 | 264 | $this->bigbluebuttonbn_mform_add_element($mform, $field['type'], $field['name'], $field['data_type'], |
265 | 265 | $field['description_key'], $cfg['recordings_deleted_default']); |
266 | 266 | $field = ['type' => 'hidden', 'name' => 'recordings_imported', 'data_type' => PARAM_INT, |
267 | - 'description_key' => null]; |
|
267 | + 'description_key' => null]; |
|
268 | 268 | if ($cfg['importrecordings_enabled'] && $cfg['recordings_imported_editable']) { |
269 | 269 | $field['type'] = 'checkbox'; |
270 | 270 | $field['description_key'] = 'mod_form_field_recordings_imported'; |
@@ -272,7 +272,7 @@ discard block |
||
272 | 272 | $this->bigbluebuttonbn_mform_add_element($mform, $field['type'], $field['name'], $field['data_type'], |
273 | 273 | $field['description_key'], $cfg['recordings_imported_default']); |
274 | 274 | $field = ['type' => 'hidden', 'name' => 'recordings_preview', 'data_type' => PARAM_INT, |
275 | - 'description_key' => null]; |
|
275 | + 'description_key' => null]; |
|
276 | 276 | if ($cfg['recordings_preview_editable']) { |
277 | 277 | $field['type'] = 'checkbox'; |
278 | 278 | $field['description_key'] = 'mod_form_field_recordings_preview'; |
@@ -342,7 +342,7 @@ discard block |
||
342 | 342 | $htmlselectiontype = html_writer::select($participantselection['type_options'], |
343 | 343 | 'bigbluebuttonbn_participant_selection_type', $participantselection['type_selected'], array(), |
344 | 344 | array('id' => 'bigbluebuttonbn_participant_selection_type', |
345 | - 'onchange' => 'M.mod_bigbluebuttonbn.modform.participantSelectionSet(); return 0;')); |
|
345 | + 'onchange' => 'M.mod_bigbluebuttonbn.modform.participantSelectionSet(); return 0;')); |
|
346 | 346 | $htmlselectionoptions = html_writer::select($participantselection['options'], 'bigbluebuttonbn_participant_selection', |
347 | 347 | $participantselection['selected'], array(), |
348 | 348 | array('id' => 'bigbluebuttonbn_participant_selection', 'disabled' => 'disabled')); |
@@ -350,7 +350,7 @@ discard block |
||
350 | 350 | 'type' => 'button', 'class' => 'btn btn-secondary', |
351 | 351 | 'value' => get_string('mod_form_field_participant_list_action_add', 'bigbluebuttonbn'), |
352 | 352 | 'onclick' => 'M.mod_bigbluebuttonbn.modform.participantAdd(); return 0;' |
353 | - )); |
|
353 | + )); |
|
354 | 354 | $htmladdparticipant = html_writer::tag('div', |
355 | 355 | $htmlselectiontype . ' ' . $htmlselectionoptions . ' ' . $htmlselectioninput, null); |
356 | 356 | $mform->addElement('html', "\n\n"); |
@@ -392,9 +392,9 @@ discard block |
||
392 | 392 | $field['type'] = 'select'; |
393 | 393 | $field['data_type'] = PARAM_TEXT; |
394 | 394 | $field['description_key'] = 'mod_form_field_block_clienttype'; |
395 | - $choices = array(BIGBLUEBUTTON_CLIENTTYPE_FLASH => get_string('mod_form_block_clienttype_flash', 'bigbluebuttonbn'), |
|
396 | - BIGBLUEBUTTON_CLIENTTYPE_HTML5 => get_string('mod_form_block_clienttype_html5', 'bigbluebuttonbn')); |
|
397 | - $mform->addElement('header', 'clienttypeselection', get_string('mod_form_block_clienttype', 'bigbluebuttonbn')); |
|
395 | + $choices = array(BIGBLUEBUTTON_CLIENTTYPE_FLASH => get_string('mod_form_block_clienttype_flash', 'bigbluebuttonbn'), |
|
396 | + BIGBLUEBUTTON_CLIENTTYPE_HTML5 => get_string('mod_form_block_clienttype_html5', 'bigbluebuttonbn')); |
|
397 | + $mform->addElement('header', 'clienttypeselection', get_string('mod_form_block_clienttype', 'bigbluebuttonbn')); |
|
398 | 398 | $this->bigbluebuttonbn_mform_add_element($mform, $field['type'], $field['name'], $field['data_type'], |
399 | 399 | $field['description_key'], $cfg['clienttype_default'], $choices); |
400 | 400 | return; |
@@ -26,8 +26,8 @@ discard block |
||
26 | 26 | |
27 | 27 | defined('MOODLE_INTERNAL') || die(); |
28 | 28 | |
29 | -require_once(dirname(__FILE__).'/locallib.php'); |
|
30 | -require_once($CFG->dirroot.'/course/moodleform_mod.php'); |
|
29 | +require_once(dirname(__FILE__) . '/locallib.php'); |
|
30 | +require_once($CFG->dirroot . '/course/moodleform_mod.php'); |
|
31 | 31 | |
32 | 32 | /** |
33 | 33 | * Moodle class for mod_form. |
@@ -48,7 +48,7 @@ discard block |
||
48 | 48 | $serverversion = bigbluebuttonbn_get_server_version(); |
49 | 49 | if (is_null($serverversion)) { |
50 | 50 | print_error('general_error_unable_connect', 'bigbluebuttonbn', |
51 | - $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn'); |
|
51 | + $CFG->wwwroot . '/admin/settings.php?section=modsettingbigbluebuttonbn'); |
|
52 | 52 | return; |
53 | 53 | } |
54 | 54 | // Context. |
@@ -79,7 +79,7 @@ discard block |
||
79 | 79 | // If none is allowed, fail and return |
80 | 80 | if (empty($jsvars['instanceTypeProfiles'])) { |
81 | 81 | print_error('general_error_not_allowed_to_create_instances)', 'bigbluebuttonbn', |
82 | - $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn'); |
|
82 | + $CFG->wwwroot . '/admin/settings.php?section=modsettingbigbluebuttonbn'); |
|
83 | 83 | return; |
84 | 84 | } |
85 | 85 | $this->bigbluebuttonbn_mform_add_block_profiles($mform, $jsvars['instanceTypeProfiles']); |
@@ -127,7 +127,7 @@ discard block |
||
127 | 127 | ); |
128 | 128 | $defaultvalues['presentation'] = $draftitemid; |
129 | 129 | } catch (Exception $e) { |
130 | - debugging('Presentation could not be loaded: '.$e->getMessage(), DEBUG_DEVELOPER); |
|
130 | + debugging('Presentation could not be loaded: ' . $e->getMessage(), DEBUG_DEVELOPER); |
|
131 | 131 | return; |
132 | 132 | } |
133 | 133 | } |
@@ -453,7 +453,7 @@ discard block |
||
453 | 453 | return; |
454 | 454 | } |
455 | 455 | $mform->addElement($type, $name, get_string($descriptionkey, 'bigbluebuttonbn'), $options); |
456 | - if (get_string_manager()->string_exists($descriptionkey.'_help', 'bigbluebuttonbn')) { |
|
456 | + if (get_string_manager()->string_exists($descriptionkey . '_help', 'bigbluebuttonbn')) { |
|
457 | 457 | $mform->addHelpButton($name, $descriptionkey, 'bigbluebuttonbn'); |
458 | 458 | } |
459 | 459 | if (!empty($rule)) { |
@@ -28,7 +28,6 @@ |
||
28 | 28 | defined('MOODLE_INTERNAL') || die(); |
29 | 29 | |
30 | 30 | use context_module; |
31 | -use mod_bigbluebuttonbn_external; |
|
32 | 31 | require_once($CFG->dirroot . '/mod/bigbluebuttonbn/locallib.php'); |
33 | 32 | |
34 | 33 | /** |
@@ -54,7 +54,7 @@ discard block |
||
54 | 54 | |
55 | 55 | global $OUTPUT, $SESSION, $CFG; |
56 | 56 | |
57 | - $args = (object) $args; |
|
57 | + $args = (object)$args; |
|
58 | 58 | $viewinstance = bigbluebuttonbn_view_validator($args->cmid, null); |
59 | 59 | if (!$viewinstance) { |
60 | 60 | $error = get_string('view_error_url_missing_parameters', 'bigbluebuttonbn'); |
@@ -66,7 +66,7 @@ discard block |
||
66 | 66 | $bigbluebuttonbn = $viewinstance['bigbluebuttonbn']; |
67 | 67 | $context = context_module::instance($cm->id); |
68 | 68 | |
69 | - require_login($course->id, false , $cm, true, true); |
|
69 | + require_login($course->id, false, $cm, true, true); |
|
70 | 70 | require_capability('mod/bigbluebuttonbn:join', $context); |
71 | 71 | |
72 | 72 | // Add view event. |
@@ -111,7 +111,7 @@ discard block |
||
111 | 111 | |
112 | 112 | // Check if the BBB server is working. |
113 | 113 | $serverversion = bigbluebuttonbn_get_server_version(); |
114 | - $bbbsession['serverversion'] = (string) $serverversion; |
|
114 | + $bbbsession['serverversion'] = (string)$serverversion; |
|
115 | 115 | if (is_null($serverversion)) { |
116 | 116 | |
117 | 117 | if ($bbbsession['administrator']) { |
@@ -138,7 +138,7 @@ discard block |
||
138 | 138 | |
139 | 139 | // Operation URLs. |
140 | 140 | $bbbsession['bigbluebuttonbnURL'] = $CFG->wwwroot . '/mod/bigbluebuttonbn/view.php?id=' . $bbbsession['cm']->id; |
141 | - $bbbsession['logoutURL'] = $CFG->wwwroot . '/mod/bigbluebuttonbn/bbb_view.php?action=logout&id='.$args->cmid . |
|
141 | + $bbbsession['logoutURL'] = $CFG->wwwroot . '/mod/bigbluebuttonbn/bbb_view.php?action=logout&id=' . $args->cmid . |
|
142 | 142 | '&bn=' . $bbbsession['bigbluebuttonbn']->id; |
143 | 143 | $bbbsession['recordingReadyURL'] = $CFG->wwwroot . '/mod/bigbluebuttonbn/bbb_broker.php?action=recording_' . |
144 | 144 | 'ready&bigbluebuttonbn=' . $bbbsession['bigbluebuttonbn']->id; |
@@ -181,7 +181,7 @@ discard block |
||
181 | 181 | } |
182 | 182 | if ($response['returncode'] == 'FAILED') { |
183 | 183 | // The meeting could not be created. |
184 | - $errorkey = bigbluebuttonbn_get_error_key($response['messageKey'], 'view_error_create'); |
|
184 | + $errorkey = bigbluebuttonbn_get_error_key($response['messageKey'], 'view_error_create'); |
|
185 | 185 | $e = get_string($errorkey, 'bigbluebuttonbn'); |
186 | 186 | return(self::mobile_print_error($e)); |
187 | 187 | } |
@@ -194,7 +194,7 @@ discard block |
||
194 | 194 | bigbluebuttonbn_event_log(\mod_bigbluebuttonbn\event\events::$events['meeting_create'], $bigbluebuttonbn); |
195 | 195 | // Insert a record that meeting was created. |
196 | 196 | $overrides = array('meetingid' => $bbbsession['meetingid']); |
197 | - $meta = '{"record":'.($bbbsession['record'] ? 'true' : 'false').'}'; |
|
197 | + $meta = '{"record":' . ($bbbsession['record'] ? 'true' : 'false') . '}'; |
|
198 | 198 | bigbluebuttonbn_log($bbbsession['bigbluebuttonbn'], BIGBLUEBUTTONBN_LOG_EVENT_CREATE, $overrides, $meta); |
199 | 199 | } |
200 | 200 | |
@@ -212,7 +212,7 @@ discard block |
||
212 | 212 | |
213 | 213 | $data = array( |
214 | 214 | 'bigbluebuttonbn' => $bigbluebuttonbn, |
215 | - 'bbbsession' => (object) $bbbsession, |
|
215 | + 'bbbsession' => (object)$bbbsession, |
|
216 | 216 | 'urltojoin' => $urltojoin, |
217 | 217 | 'cmid' => $cm->id, |
218 | 218 | 'courseid' => $args->courseid |
@@ -58,7 +58,7 @@ discard block |
||
58 | 58 | $session['importrecordings'] = ($session['managerecordings']); |
59 | 59 | $session['modPW'] = $session['bigbluebuttonbn']->moderatorpass; |
60 | 60 | $session['viewerPW'] = $session['bigbluebuttonbn']->viewerpass; |
61 | - $session['meetingid'] = $session['bigbluebuttonbn']->meetingid.'-'.$session['course']->id.'-'. |
|
61 | + $session['meetingid'] = $session['bigbluebuttonbn']->meetingid . '-' . $session['course']->id . '-' . |
|
62 | 62 | $session['bigbluebuttonbn']->id; |
63 | 63 | $session['meetingname'] = $session['bigbluebuttonbn']->name; |
64 | 64 | $session['meetingdescription'] = $session['bigbluebuttonbn']->intro; |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | $session['welcome'] = get_string('mod_form_field_welcome_default', 'bigbluebuttonbn'); |
78 | 78 | } |
79 | 79 | if ($session['bigbluebuttonbn']->record) { |
80 | - $session['welcome'] .= '<br><br>'.get_string('bbbrecordwarning', 'bigbluebuttonbn'); |
|
80 | + $session['welcome'] .= '<br><br>' . get_string('bbbrecordwarning', 'bigbluebuttonbn'); |
|
81 | 81 | } |
82 | 82 | $session['openingtime'] = $session['bigbluebuttonbn']->openingtime; |
83 | 83 | $session['closingtime'] = $session['bigbluebuttonbn']->closingtime; |
@@ -88,7 +88,7 @@ discard block |
||
88 | 88 | $session['originServerName'] = $parsedurl['host']; |
89 | 89 | $session['originServerUrl'] = $CFG->wwwroot; |
90 | 90 | $session['originServerCommonName'] = ''; |
91 | - $session['originTag'] = 'moodle-mod_bigbluebuttonbn ('.get_config('mod_bigbluebuttonbn', 'version').')'; |
|
91 | + $session['originTag'] = 'moodle-mod_bigbluebuttonbn (' . get_config('mod_bigbluebuttonbn', 'version') . ')'; |
|
92 | 92 | $session['bnserver'] = bigbluebuttonbn_is_bn_server(); |
93 | 93 | $session['clienttype'] = \mod_bigbluebuttonbn\locallib\config::get('clienttype_default'); |
94 | 94 | |
@@ -201,7 +201,7 @@ discard block |
||
201 | 201 | $data['welcome'] .= '<br><br>'; |
202 | 202 | $data['welcome'] .= str_replace( |
203 | 203 | '%duration%', |
204 | - (string) $durationtime, |
|
204 | + (string)$durationtime, |
|
205 | 205 | get_string('bbbdurationwarning', 'bigbluebuttonbn') |
206 | 206 | ); |
207 | 207 | } |
@@ -24,8 +24,8 @@ discard block |
||
24 | 24 | * @author Fred Dixon (ffdixon [at] blindsidenetworks [dt] com) |
25 | 25 | */ |
26 | 26 | |
27 | -require_once(dirname(dirname(dirname(__FILE__))).'/config.php'); |
|
28 | -require_once(dirname(__FILE__).'/locallib.php'); |
|
27 | +require_once(dirname(dirname(dirname(__FILE__))) . '/config.php'); |
|
28 | +require_once(dirname(__FILE__) . '/locallib.php'); |
|
29 | 29 | |
30 | 30 | $id = required_param('id', PARAM_INT); |
31 | 31 | $bn = optional_param('bn', 0, PARAM_INT); |
@@ -57,19 +57,19 @@ discard block |
||
57 | 57 | if (is_null($serverversion)) { |
58 | 58 | if ($bbbsession['administrator']) { |
59 | 59 | print_error('view_error_unable_join', 'bigbluebuttonbn', |
60 | - $CFG->wwwroot.'/admin/settings.php?section=modsettingbigbluebuttonbn'); |
|
60 | + $CFG->wwwroot . '/admin/settings.php?section=modsettingbigbluebuttonbn'); |
|
61 | 61 | exit; |
62 | 62 | } |
63 | 63 | if ($bbbsession['moderator']) { |
64 | 64 | print_error('view_error_unable_join_teacher', 'bigbluebuttonbn', |
65 | - $CFG->wwwroot.'/course/view.php?id='.$bigbluebuttonbn->course); |
|
65 | + $CFG->wwwroot . '/course/view.php?id=' . $bigbluebuttonbn->course); |
|
66 | 66 | exit; |
67 | 67 | } |
68 | 68 | print_error('view_error_unable_join_student', 'bigbluebuttonbn', |
69 | - $CFG->wwwroot.'/course/view.php?id='.$bigbluebuttonbn->course); |
|
69 | + $CFG->wwwroot . '/course/view.php?id=' . $bigbluebuttonbn->course); |
|
70 | 70 | exit; |
71 | 71 | } |
72 | -$bbbsession['serverversion'] = (string) $serverversion; |
|
72 | +$bbbsession['serverversion'] = (string)$serverversion; |
|
73 | 73 | |
74 | 74 | // Mark viewed by user (if required). |
75 | 75 | $completion = new completion_info($course); |
@@ -77,7 +77,7 @@ discard block |
||
77 | 77 | |
78 | 78 | // Print the page header. |
79 | 79 | $PAGE->set_context($context); |
80 | -$PAGE->set_url($CFG->wwwroot.'/mod/bigbluebuttonbn/view.php', array('id' => $cm->id)); |
|
80 | +$PAGE->set_url($CFG->wwwroot . '/mod/bigbluebuttonbn/view.php', array('id' => $cm->id)); |
|
81 | 81 | $PAGE->set_title(format_string($bigbluebuttonbn->name)); |
82 | 82 | $PAGE->set_cacheable(false); |
83 | 83 | $PAGE->set_heading($course->fullname); |
@@ -87,11 +87,11 @@ discard block |
||
87 | 87 | if (!has_capability('moodle/category:manage', $context) && !has_capability('mod/bigbluebuttonbn:join', $context)) { |
88 | 88 | echo $OUTPUT->header(); |
89 | 89 | if (isguestuser()) { |
90 | - echo $OUTPUT->confirm('<p>'.get_string('view_noguests', 'bigbluebuttonbn').'</p>'.get_string('liketologin'), |
|
91 | - get_login_url(), $CFG->wwwroot.'/course/view.php?id='.$course->id); |
|
90 | + echo $OUTPUT->confirm('<p>' . get_string('view_noguests', 'bigbluebuttonbn') . '</p>' . get_string('liketologin'), |
|
91 | + get_login_url(), $CFG->wwwroot . '/course/view.php?id=' . $course->id); |
|
92 | 92 | } else { |
93 | - echo $OUTPUT->confirm('<p>'.get_string('view_nojoin', 'bigbluebuttonbn').'</p>'.get_string('liketologin'), |
|
94 | - get_login_url(), $CFG->wwwroot.'/course/view.php?id='.$course->id); |
|
93 | + echo $OUTPUT->confirm('<p>' . get_string('view_nojoin', 'bigbluebuttonbn') . '</p>' . get_string('liketologin'), |
|
94 | + get_login_url(), $CFG->wwwroot . '/course/view.php?id=' . $course->id); |
|
95 | 95 | } |
96 | 96 | echo $OUTPUT->footer(); |
97 | 97 | exit; |
@@ -99,7 +99,7 @@ discard block |
||
99 | 99 | |
100 | 100 | // Operation URLs. |
101 | 101 | $bbbsession['bigbluebuttonbnURL'] = $CFG->wwwroot . '/mod/bigbluebuttonbn/view.php?id=' . $bbbsession['cm']->id; |
102 | -$bbbsession['logoutURL'] = $CFG->wwwroot . '/mod/bigbluebuttonbn/bbb_view.php?action=logout&id='.$id . |
|
102 | +$bbbsession['logoutURL'] = $CFG->wwwroot . '/mod/bigbluebuttonbn/bbb_view.php?action=logout&id=' . $id . |
|
103 | 103 | '&bn=' . $bbbsession['bigbluebuttonbn']->id; |
104 | 104 | $bbbsession['recordingReadyURL'] = $CFG->wwwroot . '/mod/bigbluebuttonbn/bbb_broker.php?action=recording_' . |
105 | 105 | 'ready&bigbluebuttonbn=' . $bbbsession['bigbluebuttonbn']->id; |
@@ -119,7 +119,7 @@ discard block |
||
119 | 119 | echo $OUTPUT->footer(); |
120 | 120 | |
121 | 121 | // Shows version as a comment. |
122 | -echo '<!-- '.$bbbsession['originTag'].' -->'."\n"; |
|
122 | +echo '<!-- ' . $bbbsession['originTag'] . ' -->' . "\n"; |
|
123 | 123 | |
124 | 124 | // Initialize session variable used across views. |
125 | 125 | $SESSION->bigbluebuttonbn_bbbsession = $bbbsession; |
@@ -151,8 +151,8 @@ discard block |
||
151 | 151 | $groupname = groups_get_group_name($bbbsession['group']); |
152 | 152 | } |
153 | 153 | // Assign group default values. |
154 | - $bbbsession['meetingid'] .= '['.$bbbsession['group'].']'; |
|
155 | - $bbbsession['meetingname'] .= ' ('.$groupname.')'; |
|
154 | + $bbbsession['meetingid'] .= '[' . $bbbsession['group'] . ']'; |
|
155 | + $bbbsession['meetingname'] .= ' (' . $groupname . ')'; |
|
156 | 156 | if (count($groups) == 0) { |
157 | 157 | // Only the All participants group exists. |
158 | 158 | bigbluebuttonbn_view_message_box($bbbsession, get_string('view_groups_notenrolled_warning', 'bigbluebuttonbn'), 'info'); |
@@ -162,7 +162,7 @@ discard block |
||
162 | 162 | if (has_capability('moodle/site:accessallgroups', $context)) { |
163 | 163 | bigbluebuttonbn_view_message_box($bbbsession, get_string('view_groups_selection_warning', 'bigbluebuttonbn')); |
164 | 164 | } |
165 | - $urltoroot = $CFG->wwwroot.'/mod/bigbluebuttonbn/view.php?id='.$bbbsession['cm']->id; |
|
165 | + $urltoroot = $CFG->wwwroot . '/mod/bigbluebuttonbn/view.php?id=' . $bbbsession['cm']->id; |
|
166 | 166 | groups_print_activity_menu($bbbsession['cm'], $urltoroot); |
167 | 167 | echo '<br><br>'; |
168 | 168 | } |
@@ -229,7 +229,7 @@ discard block |
||
229 | 229 | $recordingsdisabled = get_string('view_message_recordings_disabled', 'bigbluebuttonbn'); |
230 | 230 | $output .= bigbluebuttonbn_render_warning($recordingsdisabled, 'danger'); |
231 | 231 | } |
232 | - echo $output.html_writer::empty_tag('br').html_writer::empty_tag('br').html_writer::empty_tag('br'); |
|
232 | + echo $output . html_writer::empty_tag('br') . html_writer::empty_tag('br') . html_writer::empty_tag('br'); |
|
233 | 233 | $PAGE->requires->yui_module('moodle-mod_bigbluebuttonbn-broker', 'M.mod_bigbluebuttonbn.broker.init', array($jsvars)); |
234 | 234 | } |
235 | 235 | |
@@ -298,12 +298,12 @@ discard block |
||
298 | 298 | // JavaScript variables for room. |
299 | 299 | $openingtime = ''; |
300 | 300 | if ($bbbsession['openingtime']) { |
301 | - $openingtime = get_string('mod_form_field_openingtime', 'bigbluebuttonbn').': '. |
|
301 | + $openingtime = get_string('mod_form_field_openingtime', 'bigbluebuttonbn') . ': ' . |
|
302 | 302 | userdate($bbbsession['openingtime']); |
303 | 303 | } |
304 | 304 | $closingtime = ''; |
305 | 305 | if ($bbbsession['closingtime']) { |
306 | - $closingtime = get_string('mod_form_field_closingtime', 'bigbluebuttonbn').': '. |
|
306 | + $closingtime = get_string('mod_form_field_closingtime', 'bigbluebuttonbn') . ': ' . |
|
307 | 307 | userdate($bbbsession['closingtime']); |
308 | 308 | } |
309 | 309 | $jsvars += array( |
@@ -320,7 +320,7 @@ discard block |
||
320 | 320 | $output .= $OUTPUT->box_end(); |
321 | 321 | // Action button box. |
322 | 322 | $output .= $OUTPUT->box_start('generalbox boxaligncenter', 'bigbluebuttonbn_view_action_button_box'); |
323 | - $output .= '<br><br><span id="join_button"></span> <span id="end_button"></span>'."\n"; |
|
323 | + $output .= '<br><br><span id="join_button"></span> <span id="end_button"></span>' . "\n"; |
|
324 | 324 | $output .= $OUTPUT->box_end(); |
325 | 325 | if ($activity == 'ended') { |
326 | 326 | $output .= bigbluebuttonbn_view_ended($bbbsession); |
@@ -373,7 +373,7 @@ discard block |
||
373 | 373 | // If there are meetings with recordings load the data to the table. |
374 | 374 | if ($bbbsession['bigbluebuttonbn']->recordings_html) { |
375 | 375 | // Render a plain html table. |
376 | - return bigbluebuttonbn_output_recording_table($bbbsession, $recordings)."\n"; |
|
376 | + return bigbluebuttonbn_output_recording_table($bbbsession, $recordings) . "\n"; |
|
377 | 377 | } |
378 | 378 | // JavaScript variables for recordings with YUI. |
379 | 379 | $jsvars += array( |
@@ -401,8 +401,8 @@ discard block |
||
401 | 401 | array('type' => 'button', |
402 | 402 | 'value' => get_string('view_recording_button_import', 'bigbluebuttonbn'), |
403 | 403 | 'class' => 'btn btn-secondary', |
404 | - 'onclick' => 'window.location=\''.$CFG->wwwroot.'/mod/bigbluebuttonbn/import_view.php?bn='. |
|
405 | - $bbbsession['bigbluebuttonbn']->id.'\'')); |
|
404 | + 'onclick' => 'window.location=\'' . $CFG->wwwroot . '/mod/bigbluebuttonbn/import_view.php?bn=' . |
|
405 | + $bbbsession['bigbluebuttonbn']->id . '\'')); |
|
406 | 406 | $output = html_writer::empty_tag('br'); |
407 | 407 | $output .= html_writer::tag('span', $button, array('id' => 'import_recording_links_button')); |
408 | 408 | $output .= html_writer::tag('span', '', array('id' => 'import_recording_links_table')); |
@@ -421,10 +421,10 @@ discard block |
||
421 | 421 | if (!is_null($bbbsession['presentation']['url'])) { |
422 | 422 | $attributes = array('title' => $bbbsession['presentation']['name']); |
423 | 423 | $icon = new pix_icon($bbbsession['presentation']['icon'], $bbbsession['presentation']['mimetype_description']); |
424 | - return '<h4>'.get_string('view_section_title_presentation', 'bigbluebuttonbn').'</h4>'. |
|
425 | - $OUTPUT->action_icon($bbbsession['presentation']['url'], $icon, null, array(), false). |
|
424 | + return '<h4>' . get_string('view_section_title_presentation', 'bigbluebuttonbn') . '</h4>' . |
|
425 | + $OUTPUT->action_icon($bbbsession['presentation']['url'], $icon, null, array(), false) . |
|
426 | 426 | $OUTPUT->action_link($bbbsession['presentation']['url'], |
427 | - $bbbsession['presentation']['name'], null, $attributes).'<br><br>'; |
|
427 | + $bbbsession['presentation']['name'], null, $attributes) . '<br><br>'; |
|
428 | 428 | } |
429 | 429 | return ''; |
430 | 430 | } |
@@ -444,12 +444,12 @@ discard block |
||
444 | 444 | $recordings = bigbluebuttonbn_get_recordings( |
445 | 445 | $bbbsession['course']->id, $bigbluebuttonbnid, $enabledfeatures['showroom'], |
446 | 446 | $bbbsession['bigbluebuttonbn']->recordings_deleted |
447 | - ); |
|
447 | + ); |
|
448 | 448 | if ($enabledfeatures['importrecordings']) { |
449 | 449 | // Get recording links. |
450 | 450 | $recordingsimported = bigbluebuttonbn_get_recordings_imported_array( |
451 | 451 | $bbbsession['course']->id, $bigbluebuttonbnid, $enabledfeatures['showroom'] |
452 | - ); |
|
452 | + ); |
|
453 | 453 | /* Perform aritmetic addition instead of merge so the imported recordings corresponding to existent |
454 | 454 | * recordings are not included. */ |
455 | 455 | if ($bbbsession['bigbluebuttonbn']->recordings_imported) { |
@@ -467,7 +467,7 @@ discard block |
||
467 | 467 | // JavaScript variables for recordings. |
468 | 468 | $jsvars += array( |
469 | 469 | 'recordings_html' => $bbbsession['bigbluebuttonbn']->recordings_html == '1', |
470 | - ); |
|
470 | + ); |
|
471 | 471 | // If there are meetings with recordings load the data to the table. |
472 | 472 | if ($bbbsession['bigbluebuttonbn']->recordings_html) { |
473 | 473 | // Render a plain html table. |
@@ -477,7 +477,7 @@ discard block |
||
477 | 477 | $jsvars += array( |
478 | 478 | 'columns' => bigbluebuttonbn_get_recording_columns($bbbsession), |
479 | 479 | 'data' => bigbluebuttonbn_get_recording_data($bbbsession, $recordings), |
480 | - ); |
|
480 | + ); |
|
481 | 481 | // Render a YUI table. |
482 | 482 | $reset = get_string('reset'); |
483 | 483 | $search = get_string('search'); |
@@ -506,10 +506,10 @@ discard block |
||
506 | 506 | } |
507 | 507 | $button = html_writer::tag('input', '', |
508 | 508 | array('type' => 'button', |
509 | - 'value' => get_string('view_recording_button_import', 'bigbluebuttonbn'), |
|
510 | - 'class' => 'btn btn-secondary', |
|
511 | - 'onclick' => 'window.location=\''.$CFG->wwwroot.'/mod/bigbluebuttonbn/import_view.php?bn='. |
|
512 | - $bbbsession['bigbluebuttonbn']->id.'\'')); |
|
509 | + 'value' => get_string('view_recording_button_import', 'bigbluebuttonbn'), |
|
510 | + 'class' => 'btn btn-secondary', |
|
511 | + 'onclick' => 'window.location=\''.$CFG->wwwroot.'/mod/bigbluebuttonbn/import_view.php?bn='. |
|
512 | + $bbbsession['bigbluebuttonbn']->id.'\'')); |
|
513 | 513 | $output = html_writer::empty_tag('br'); |
514 | 514 | $output .= html_writer::tag('span', $button, array('id' => 'import_recording_links_button')); |
515 | 515 | $output .= html_writer::tag('span', '', array('id' => 'import_recording_links_table')); |
@@ -570,5 +570,5 @@ discard block |
||
570 | 570 | (string)\mod_bigbluebuttonbn\locallib\config::get('general_warning_button_href'), |
571 | 571 | (string)\mod_bigbluebuttonbn\locallib\config::get('general_warning_button_text'), |
572 | 572 | (string)\mod_bigbluebuttonbn\locallib\config::get('general_warning_button_class') |
573 | - ); |
|
573 | + ); |
|
574 | 574 | } |
@@ -260,7 +260,6 @@ |
||
260 | 260 | /** |
261 | 261 | * Add Join Session button. |
262 | 262 | * |
263 | - * @param boolean $moderator |
|
264 | 263 | * @param object $course |
265 | 264 | * @param object $bigbluebuttonbn |
266 | 265 | * @param object $groupobj |
@@ -24,8 +24,8 @@ discard block |
||
24 | 24 | * @author Fred Dixon (ffdixon [at] blindsidenetworks [dt] com) |
25 | 25 | */ |
26 | 26 | |
27 | -require_once(dirname(dirname(dirname(__FILE__))).'/config.php'); |
|
28 | -require_once(dirname(__FILE__).'/locallib.php'); |
|
27 | +require_once(dirname(dirname(dirname(__FILE__))) . '/config.php'); |
|
28 | +require_once(dirname(__FILE__) . '/locallib.php'); |
|
29 | 29 | |
30 | 30 | $id = required_param('id', PARAM_INT); |
31 | 31 | $a = optional_param('a', 0, PARAM_INT); |
@@ -89,13 +89,13 @@ discard block |
||
89 | 89 | if ($moderator || $administrator) { |
90 | 90 | bigbluebuttonbn_event_log(\mod_bigbluebuttonbn\event\events::$events['meeting_end'], $bigbluebuttonbn); |
91 | 91 | echo get_string('index_ending', 'bigbluebuttonbn'); |
92 | - $meetingid = $bigbluebuttonbn->meetingid.'-'.$course->id.'-'.$bigbluebuttonbn->id; |
|
92 | + $meetingid = $bigbluebuttonbn->meetingid . '-' . $course->id . '-' . $bigbluebuttonbn->id; |
|
93 | 93 | if ($g != '0') { |
94 | - $meetingid .= '['.$g.']'; |
|
94 | + $meetingid .= '[' . $g . ']'; |
|
95 | 95 | } |
96 | 96 | |
97 | 97 | bigbluebuttonbn_end_meeting($meetingid, $bigbluebuttonbn->moderatorpass); |
98 | - redirect('index.php?id='.$id); |
|
98 | + redirect('index.php?id=' . $id); |
|
99 | 99 | } |
100 | 100 | } |
101 | 101 | |
@@ -112,7 +112,7 @@ discard block |
||
112 | 112 | |
113 | 113 | $groupmode = groups_get_activity_groupmode($cm) > 0; |
114 | 114 | if ($groupmode) { |
115 | - $groupobj = (object) array('id' => 0, 'name' => get_string('allparticipants')); |
|
115 | + $groupobj = (object)array('id' => 0, 'name' => get_string('allparticipants')); |
|
116 | 116 | } |
117 | 117 | $table->data[] = bigbluebuttonbn_index_display_room($canmoderate, $course, $bigbluebuttonbn, $groupobj); |
118 | 118 | if ($groupmode) { |
@@ -142,12 +142,12 @@ discard block |
||
142 | 142 | * @return array |
143 | 143 | */ |
144 | 144 | function bigbluebuttonbn_index_display_room($moderator, $course, $bigbluebuttonbn, $groupobj = null) { |
145 | - $meetingid = $bigbluebuttonbn->meetingid.'-'.$course->id.'-'.$bigbluebuttonbn->id; |
|
145 | + $meetingid = $bigbluebuttonbn->meetingid . '-' . $course->id . '-' . $bigbluebuttonbn->id; |
|
146 | 146 | $paramgroup = ''; |
147 | 147 | $groupname = ''; |
148 | 148 | if ($groupobj) { |
149 | - $meetingid .= '['.$groupobj->id.']'; |
|
150 | - $paramgroup = '&group='.$groupobj->id; |
|
149 | + $meetingid .= '[' . $groupobj->id . ']'; |
|
150 | + $paramgroup = '&group=' . $groupobj->id; |
|
151 | 151 | $groupname = $groupobj->name; |
152 | 152 | } |
153 | 153 | $meetinginfo = bigbluebuttonbn_get_meeting_info_array($meetingid); |
@@ -162,7 +162,7 @@ discard block |
||
162 | 162 | return; |
163 | 163 | } |
164 | 164 | // Output Users in the meeting. |
165 | - $joinurl = '<a href="view.php?id='.$bigbluebuttonbn->coursemodule.$paramgroup.'">'.format_string($bigbluebuttonbn->name).'</a>'; |
|
165 | + $joinurl = '<a href="view.php?id=' . $bigbluebuttonbn->coursemodule . $paramgroup . '">' . format_string($bigbluebuttonbn->name) . '</a>'; |
|
166 | 166 | $group = $groupname; |
167 | 167 | $users = ''; |
168 | 168 | $viewerlist = ''; |
@@ -207,7 +207,7 @@ discard block |
||
207 | 207 | $attendeecount = 0; |
208 | 208 | foreach ($meetinginfo['attendees']->attendee as $attendee) { |
209 | 209 | if ($attendee->role == $role) { |
210 | - $attendeelist .= ($attendeecount++ > 0 ? ', ' : '').$attendee->fullName; |
|
210 | + $attendeelist .= ($attendeecount++ > 0 ? ', ' : '') . $attendee->fullName; |
|
211 | 211 | } |
212 | 212 | } |
213 | 213 | } |
@@ -241,18 +241,18 @@ discard block |
||
241 | 241 | function bigbluebuttonbn_index_display_room_actions($moderator, $course, $bigbluebuttonbn, $groupobj = null) { |
242 | 242 | $actions = ''; |
243 | 243 | if ($moderator) { |
244 | - $actions .= '<form name="form1" method="post" action="" class="bbb_index_form">'."\n"; |
|
245 | - $actions .= ' <INPUT type="hidden" name="id" value="'.$course->id.'">'."\n"; |
|
246 | - $actions .= ' <INPUT type="hidden" name="a" value="'.$bigbluebuttonbn->id.'">'."\n"; |
|
247 | - $actions .= ' <INPUT type="hidden" name="action" value="end">'."\n"; |
|
244 | + $actions .= '<form name="form1" method="post" action="" class="bbb_index_form">' . "\n"; |
|
245 | + $actions .= ' <INPUT type="hidden" name="id" value="' . $course->id . '">' . "\n"; |
|
246 | + $actions .= ' <INPUT type="hidden" name="a" value="' . $bigbluebuttonbn->id . '">' . "\n"; |
|
247 | + $actions .= ' <INPUT type="hidden" name="action" value="end">' . "\n"; |
|
248 | 248 | if ($groupobj != null) { |
249 | - $actions .= ' <INPUT type="hidden" name="g" value="'.$groupobj->id.'">'."\n"; |
|
249 | + $actions .= ' <INPUT type="hidden" name="g" value="' . $groupobj->id . '">' . "\n"; |
|
250 | 250 | } |
251 | 251 | $actions .= ' <INPUT type="submit" name="submit" value="' . |
252 | 252 | get_string('view_conference_action_end', 'bigbluebuttonbn') . |
253 | 253 | '" class="btn btn-primary btn-sm" onclick="return confirm(\'' . |
254 | 254 | get_string('index_confirm_end', 'bigbluebuttonbn') . '\')">' . "\n"; |
255 | - $actions .= '</form>'."\n"; |
|
255 | + $actions .= '</form>' . "\n"; |
|
256 | 256 | } |
257 | 257 | return $actions; |
258 | 258 | } |
@@ -287,15 +287,15 @@ discard block |
||
287 | 287 | $cm = get_fast_modinfo($course->id)->instances['bigbluebuttonbn'][$bigbluebuttonbn->id]; |
288 | 288 | $url = new \moodle_url('/mod/bigbluebuttonbn/bbb_view.php'); |
289 | 289 | |
290 | - $actions .= '<form action="'.$url->out().'" target="_blank" class="bbb_index_form">'."\n"; |
|
291 | - $actions .= '<input type="hidden" name="action" value="join">'."\n"; |
|
292 | - $actions .= '<input type="hidden" name="id" value="'.$cm->id.'">'."\n"; |
|
293 | - $actions .= '<input type="hidden" name="bn" value="'.$bigbluebuttonbn->id.'">'."\n"; |
|
294 | - $actions .= '<input type="hidden" name="index" value="1">'."\n"; |
|
290 | + $actions .= '<form action="' . $url->out() . '" target="_blank" class="bbb_index_form">' . "\n"; |
|
291 | + $actions .= '<input type="hidden" name="action" value="join">' . "\n"; |
|
292 | + $actions .= '<input type="hidden" name="id" value="' . $cm->id . '">' . "\n"; |
|
293 | + $actions .= '<input type="hidden" name="bn" value="' . $bigbluebuttonbn->id . '">' . "\n"; |
|
294 | + $actions .= '<input type="hidden" name="index" value="1">' . "\n"; |
|
295 | 295 | if ($groupobj) { |
296 | - $actions .= '<input type="hidden" name="group" value="'.$groupobj->id.'">'."\n"; |
|
296 | + $actions .= '<input type="hidden" name="group" value="' . $groupobj->id . '">' . "\n"; |
|
297 | 297 | } |
298 | - $actions .= '<input type="submit" value="'.get_string('view_conference_action_join', 'bigbluebuttonbn').'" />'."\n"; |
|
298 | + $actions .= '<input type="submit" value="' . get_string('view_conference_action_join', 'bigbluebuttonbn') . '" />' . "\n"; |
|
299 | 299 | $actions .= '</form>'; |
300 | 300 | |
301 | 301 | return $actions; |