|
@@ -61,62 +61,62 @@ discard block |
|
|
block discarded – undo |
|
61
|
61
|
//////////////////////////// |
|
62
|
62
|
// BigBlueButton API Calls // |
|
63
|
63
|
//////////////////////////// |
|
64
|
|
-function bigbluebuttonbn_getJoinURL( $meetingID, $userName, $PW, $SALT, $URL, $logoutURL, $configToken=NULL, $userId=NULL) { |
|
65
|
|
- $url_join = $URL."api/join?"; |
|
66
|
|
- $params = 'meetingID='.urlencode($meetingID).'&fullName='.urlencode($userName).'&password='.urlencode($PW).'&logoutURL='.urlencode($logoutURL); |
|
|
64
|
+function bigbluebuttonbn_getJoinURL($meetingID, $userName, $PW, $SALT, $URL, $logoutURL, $configToken = NULL, $userId = NULL) { |
|
|
65
|
+ $url_join = $URL . "api/join?"; |
|
|
66
|
+ $params = 'meetingID=' . urlencode($meetingID) . '&fullName=' . urlencode($userName) . '&password=' . urlencode($PW) . '&logoutURL=' . urlencode($logoutURL); |
|
67
|
67
|
if (!is_null($userId)) { |
|
68
|
|
- $params .= "&userID=".urlencode($userId); |
|
|
68
|
+ $params .= "&userID=" . urlencode($userId); |
|
69
|
69
|
} |
|
70
|
70
|
if (!is_null($configToken)) { |
|
71
|
|
- $params .= '&configToken='.$configToken; |
|
|
71
|
+ $params .= '&configToken=' . $configToken; |
|
72
|
72
|
} |
|
73
|
|
- $url = $url_join.$params.'&checksum='.sha1("join".$params.$SALT); |
|
|
73
|
+ $url = $url_join . $params . '&checksum=' . sha1("join" . $params . $SALT); |
|
74
|
74
|
return $url; |
|
75
|
75
|
} |
|
76
|
76
|
|
|
77
|
|
-function bigbluebuttonbn_getCreateMeetingURL($name, $meetingID, $attendeePW, $moderatorPW, $welcome, $logoutURL, $SALT, $URL, $record = 'false', $duration=0, $voiceBridge=0, $maxParticipants=0, $metadata=array()) { |
|
78
|
|
- $url_create = $URL."api/create?"; |
|
|
77
|
+function bigbluebuttonbn_getCreateMeetingURL($name, $meetingID, $attendeePW, $moderatorPW, $welcome, $logoutURL, $SALT, $URL, $record = 'false', $duration = 0, $voiceBridge = 0, $maxParticipants = 0, $metadata = array()) { |
|
|
78
|
+ $url_create = $URL . "api/create?"; |
|
79
|
79
|
|
|
80
|
|
- $params = 'name='.urlencode($name).'&meetingID='.urlencode($meetingID).'&attendeePW='.urlencode($attendeePW).'&moderatorPW='.urlencode($moderatorPW).'&logoutURL='.urlencode($logoutURL).'&record='.$record; |
|
|
80
|
+ $params = 'name=' . urlencode($name) . '&meetingID=' . urlencode($meetingID) . '&attendeePW=' . urlencode($attendeePW) . '&moderatorPW=' . urlencode($moderatorPW) . '&logoutURL=' . urlencode($logoutURL) . '&record=' . $record; |
|
81
|
81
|
|
|
82
|
82
|
$voiceBridge = intval($voiceBridge); |
|
83
|
83
|
if ($voiceBridge > 0 && $voiceBridge < 79999) { |
|
84
|
|
- $params .= '&voiceBridge='.$voiceBridge; |
|
|
84
|
+ $params .= '&voiceBridge=' . $voiceBridge; |
|
85
|
85
|
} |
|
86
|
86
|
|
|
87
|
87
|
$duration = intval($duration); |
|
88
|
88
|
if ($duration > 0) { |
|
89
|
|
- $params .= '&duration='.$duration; |
|
|
89
|
+ $params .= '&duration=' . $duration; |
|
90
|
90
|
} |
|
91
|
91
|
|
|
92
|
92
|
$maxParticipants = intval($maxParticipants); |
|
93
|
93
|
if ($maxParticipants > 0) { |
|
94
|
|
- $params .= '&maxParticipants='.$maxParticipants; |
|
|
94
|
+ $params .= '&maxParticipants=' . $maxParticipants; |
|
95
|
95
|
} |
|
96
|
96
|
|
|
97
|
|
- if (trim( $welcome )) { |
|
98
|
|
- $params .= '&welcome='.urlencode($welcome); |
|
|
97
|
+ if (trim($welcome)) { |
|
|
98
|
+ $params .= '&welcome=' . urlencode($welcome); |
|
99
|
99
|
} |
|
100
|
100
|
|
|
101
|
101
|
foreach ($metadata as $key => $value) { |
|
102
|
|
- $params .= '&'.$key.'='.urlencode($value); |
|
|
102
|
+ $params .= '&' . $key . '=' . urlencode($value); |
|
103
|
103
|
} |
|
104
|
104
|
|
|
105
|
|
- $url = $url_create.$params.'&checksum='.sha1("create".$params.$SALT); |
|
|
105
|
+ $url = $url_create . $params . '&checksum=' . sha1("create" . $params . $SALT); |
|
106
|
106
|
return $url; |
|
107
|
107
|
} |
|
108
|
108
|
|
|
109
|
109
|
function bigbluebuttonbn_getIsMeetingRunningURL($meetingID, $URL, $SALT) { |
|
110
|
|
- $base_url = $URL."api/isMeetingRunning?"; |
|
111
|
|
- $params = 'meetingID='.urlencode($meetingID); |
|
112
|
|
- $url = $base_url.$params.'&checksum='.sha1("isMeetingRunning".$params.$SALT); |
|
|
110
|
+ $base_url = $URL . "api/isMeetingRunning?"; |
|
|
111
|
+ $params = 'meetingID=' . urlencode($meetingID); |
|
|
112
|
+ $url = $base_url . $params . '&checksum=' . sha1("isMeetingRunning" . $params . $SALT); |
|
113
|
113
|
return $url; |
|
114
|
114
|
} |
|
115
|
115
|
|
|
116
|
116
|
function bigbluebuttonbn_getMeetingInfoURL($meetingID, $modPW, $URL, $SALT) { |
|
117
|
|
- $base_url = $URL."api/getMeetingInfo?"; |
|
118
|
|
- $params = 'meetingID='.urlencode($meetingID).'&password='.urlencode($modPW); |
|
119
|
|
- $url = $base_url.$params.'&checksum='.sha1("getMeetingInfo".$params.$SALT); |
|
|
117
|
+ $base_url = $URL . "api/getMeetingInfo?"; |
|
|
118
|
+ $params = 'meetingID=' . urlencode($meetingID) . '&password=' . urlencode($modPW); |
|
|
119
|
+ $url = $base_url . $params . '&checksum=' . sha1("getMeetingInfo" . $params . $SALT); |
|
120
|
120
|
return $url; |
|
121
|
121
|
} |
|
122
|
122
|
|
|
@@ -125,8 +125,8 @@ discard block |
|
|
block discarded – undo |
|
125
|
125
|
* @param string $SALT |
|
126
|
126
|
*/ |
|
127
|
127
|
function bigbluebuttonbn_getMeetingsURL($URL, $SALT) { |
|
128
|
|
- $base_url = $URL."api/getMeetings?"; |
|
129
|
|
- $url = $base_url.'&checksum='.sha1("getMeetings".$SALT); |
|
|
128
|
+ $base_url = $URL . "api/getMeetings?"; |
|
|
129
|
+ $url = $base_url . '&checksum=' . sha1("getMeetings" . $SALT); |
|
130
|
130
|
return $url; |
|
131
|
131
|
} |
|
132
|
132
|
|
|
@@ -1120,9 +1120,9 @@ discard block |
|
|
block discarded – undo |
|
1120
|
1120
|
* @param string $URL |
|
1121
|
1121
|
* @param string $SALT |
|
1122
|
1122
|
*/ |
|
1123
|
|
-function bigbluebuttonbn_setConfigXMLParams( $meetingID, $configXML, $URL, $SALT) { |
|
1124
|
|
- $params = 'configXML='.urlencode($configXML).'&meetingID='.urlencode($meetingID); |
|
1125
|
|
- $config_xml_params = $params.'&checksum='.sha1("setConfigXML".$params.$SALT); |
|
|
1123
|
+function bigbluebuttonbn_setConfigXMLParams($meetingID, $configXML, $URL, $SALT) { |
|
|
1124
|
+ $params = 'configXML=' . urlencode($configXML) . '&meetingID=' . urlencode($meetingID); |
|
|
1125
|
+ $config_xml_params = $params . '&checksum=' . sha1("setConfigXML" . $params . $SALT); |
|
1126
|
1126
|
return $config_xml_params; |
|
1127
|
1127
|
} |
|
1128
|
1128
|
|