|
@@ -84,8 +84,9 @@ discard block |
|
|
block discarded – undo |
|
84
|
84
|
$bbbsession['voicebridge'] = ($bigbluebuttonbn->voicebridge > 0) ? 70000 + $bigbluebuttonbn->voicebridge : $bigbluebuttonbn->voicebridge; |
|
85
|
85
|
$bbbsession['wait'] = $bigbluebuttonbn->wait; |
|
86
|
86
|
$bbbsession['record'] = $bigbluebuttonbn->record; |
|
87
|
|
-if ($bigbluebuttonbn->record) |
|
|
87
|
+if ($bigbluebuttonbn->record) { |
|
88
|
88
|
$bbbsession['welcome'] .= '<br><br>' . get_string('bbbrecordwarning', 'bigbluebuttonbn'); |
|
|
89
|
+} |
|
89
|
90
|
$bbbsession['tagging'] = $bigbluebuttonbn->tagging; |
|
90
|
91
|
|
|
91
|
92
|
$bbbsession['openingtime'] = $bigbluebuttonbn->openingtime; |
|
@@ -112,22 +113,24 @@ discard block |
|
|
block discarded – undo |
|
112
|
113
|
// Validates if the BigBlueButton server is running |
|
113
|
114
|
$serverVersion = bigbluebuttonbn_getServerVersion($bbbsession['endpoint']); |
|
114
|
115
|
if (!isset($serverVersion)) { //Server is not working |
|
115
|
|
- if ($bbbsession['administrator']) |
|
116
|
|
- print_error('view_error_unable_join', 'bigbluebuttonbn', $CFG->wwwroot . '/admin/settings.php?section=modsettingbigbluebuttonbn'); |
|
117
|
|
- else if ($bbbsession['moderator']) |
|
118
|
|
- print_error('view_error_unable_join_teacher', 'bigbluebuttonbn', $CFG->wwwroot . '/course/view.php?id=' . $bigbluebuttonbn->course); |
|
119
|
|
- else |
|
120
|
|
- print_error('view_error_unable_join_student', 'bigbluebuttonbn', $CFG->wwwroot . '/course/view.php?id=' . $bigbluebuttonbn->course); |
|
121
|
|
-} else { |
|
122
|
|
- $xml = bigbluebuttonbn_wrap_xml_load_file(bigbluebuttonbn_getMeetingsURL($bbbsession['endpoint'], $bbbsession['shared_secret'])); |
|
123
|
|
- if (!isset($xml) || !isset($xml->returncode) || $xml->returncode == 'FAILED') { // The shared secret is wrong |
|
124
|
|
- if ($bbbsession['administrator']) |
|
|
116
|
+ if ($bbbsession['administrator']) { |
|
125
|
117
|
print_error('view_error_unable_join', 'bigbluebuttonbn', $CFG->wwwroot . '/admin/settings.php?section=modsettingbigbluebuttonbn'); |
|
126
|
|
- else if ($bbbsession['moderator']) |
|
|
118
|
+ } else if ($bbbsession['moderator']) { |
|
127
|
119
|
print_error('view_error_unable_join_teacher', 'bigbluebuttonbn', $CFG->wwwroot . '/course/view.php?id=' . $bigbluebuttonbn->course); |
|
128
|
|
- else |
|
|
120
|
+ } else { |
|
129
|
121
|
print_error('view_error_unable_join_student', 'bigbluebuttonbn', $CFG->wwwroot . '/course/view.php?id=' . $bigbluebuttonbn->course); |
|
130
|
122
|
} |
|
|
123
|
+ } else { |
|
|
124
|
+ $xml = bigbluebuttonbn_wrap_xml_load_file(bigbluebuttonbn_getMeetingsURL($bbbsession['endpoint'], $bbbsession['shared_secret'])); |
|
|
125
|
+ if (!isset($xml) || !isset($xml->returncode) || $xml->returncode == 'FAILED') { // The shared secret is wrong |
|
|
126
|
+ if ($bbbsession['administrator']) { |
|
|
127
|
+ print_error('view_error_unable_join', 'bigbluebuttonbn', $CFG->wwwroot . '/admin/settings.php?section=modsettingbigbluebuttonbn'); |
|
|
128
|
+ } else if ($bbbsession['moderator']) { |
|
|
129
|
+ print_error('view_error_unable_join_teacher', 'bigbluebuttonbn', $CFG->wwwroot . '/course/view.php?id=' . $bigbluebuttonbn->course); |
|
|
130
|
+ } else { |
|
|
131
|
+ print_error('view_error_unable_join_student', 'bigbluebuttonbn', $CFG->wwwroot . '/course/view.php?id=' . $bigbluebuttonbn->course); |
|
|
132
|
+ } |
|
|
133
|
+ } |
|
131
|
134
|
} |
|
132
|
135
|
|
|
133
|
136
|
// Mark viewed by user (if required) |
|
@@ -338,7 +341,9 @@ discard block |
|
|
block discarded – undo |
|
338
|
341
|
} |
|
339
|
342
|
//Generates the meetingID string |
|
340
|
343
|
foreach ($mIDs as $mID) { |
|
341
|
|
- if (strlen($meetingID) > 0) $meetingID .= ','; |
|
|
344
|
+ if (strlen($meetingID) > 0) { |
|
|
345
|
+ $meetingID .= ','; |
|
|
346
|
+ } |
|
342
|
347
|
$meetingID .= $mID; |
|
343
|
348
|
} |
|
344
|
349
|
} |