diff --git a/plugin/Live/webRTC.js b/plugin/Live/webRTC.js index 08b667dca..11b2af82a 100644 --- a/plugin/Live/webRTC.js +++ b/plugin/Live/webRTC.js @@ -1,54 +1,54 @@ window.addEventListener('message', event => { if (event.data.startLiveRestream) { startLiveRestream(event.data.m3u8); }else if (event.data.webRTCModalConfig) { console.log('event.data.webRTCModalConfig', event.data.webRTCModalConfig, typeof webRTCModalConfigShow); if(event.data.webRTCModalConfig==1){ if(typeof webRTCModalConfigShow =='function'){ webRTCModalConfigShow(); } }else{ if(typeof webRTCModalConfigHide =='function'){ webRTCModalConfigHide(); } } } }); function startLiveRestream(m3u8) { //console.log('WebRTCLiveCam: startLive'); modal.showPleaseWait(); $.ajax({ url: webSiteRootURL + '/plugin/Live/webRTCToLive.json.php', method: 'POST', data: { 'm3u8': m3u8, - 'live_servers_id': '' + 'live_servers_id': live_servers_id }, success: function (response) { if (response.error) { webRTCDisconnect(); avideoAlertError(response.msg); } else { avideoToastSuccess(response.msg); //document.querySelector("iframe").contentWindow.postMessage({setLiveStart: 1}, "*"); } modal.hidePleaseWait(); } }); } function webRTCConnect() { modal.showPleaseWait(); document.querySelector("iframe").contentWindow.postMessage({setLiveStart: 1}, "*"); } function webRTCDisconnect() { document.querySelector("iframe").contentWindow.postMessage({setLiveStop: 1}, "*"); } function webRTCConfiguration() { document.querySelector("iframe").contentWindow.postMessage({setConfiguration: 1}, "*"); } \ No newline at end of file diff --git a/plugin/Live/webRTC.php b/plugin/Live/webRTC.php index 5af9be688..9d1b814e1 100644 --- a/plugin/Live/webRTC.php +++ b/plugin/Live/webRTC.php @@ -1,86 +1,87 @@ webRTC_player; $iframeURL = addQueryStringParameter($iframeURL, 'webSiteRootURL', $global['webSiteRootURL']); $iframeURL = addQueryStringParameter($iframeURL, 'userHash', Live::getUserHash(User::getId())); ?> \ No newline at end of file diff --git a/plugin/Live/webcamFullscreen.php b/plugin/Live/webcamFullscreen.php index 68d82413b..b14ece227 100644 --- a/plugin/Live/webcamFullscreen.php +++ b/plugin/Live/webcamFullscreen.php @@ -1,162 +1,163 @@ webRTC_player; $iframeURL = addQueryStringParameter($iframeURL, 'webSiteRootURL', $global['webSiteRootURL']); $iframeURL = addQueryStringParameter($iframeURL, 'userHash', Live::getUserHash(User::getId())); $chatURL = ''; $chat = AVideoPlugin::loadPluginIfEnabled('Chat2'); if (!empty($chat)) { $chatURL = Chat2::getChatRoomLink(User::getId(), 1, 1, 1, true, 1); if(!empty($_REQUEST['user'])){ $chatURL = addQueryStringParameter($chatURL, 'user', $_REQUEST['user']); } if(!empty($_REQUEST['pass'])){ $chatURL = addQueryStringParameter($chatURL, 'pass', $_REQUEST['pass']); } } ?> <?php echo $config->getWebSiteTitle(); ?>