diff --git a/view/videoEmbeded.php b/view/videoEmbeded.php index ca178dd95..fa7ba8b80 100644 --- a/view/videoEmbeded.php +++ b/view/videoEmbeded.php @@ -1,397 +1,389 @@ login(false, true); } if (!empty($_GET['v'])) { $video = Video::getVideo($_GET['v'], "", true, false, false, true); //$video['id'] = $_GET['v']; } else if (!empty($_GET['videoName'])) { $video = Video::getVideoFromCleanTitle($_GET['videoName']); } Video::unsetAddView($video['id']); AVideoPlugin::getEmbed($video['id']); if (empty($video)) { die("Video not found"); } $customizedAdvanced = AVideoPlugin::getObjectDataIfEnabled('CustomizeAdvanced'); $objSecure = AVideoPlugin::loadPluginIfEnabled('SecureVideosDirectory'); if (!empty($objSecure)) { $objSecure->verifyEmbedSecurity(); } $imgw = 1280; $imgh = 720; if ($video['type'] !== "pdf") { $source = Video::getSourceFile($video['filename']); $img = $source['url']; $data = getimgsize($source['path']); $imgw = $data[0]; $imgh = $data[1]; } else if (($video['type'] !== "audio") && ($video['type'] !== "linkAudio")) { $source = Video::getSourceFile($video['filename']); $img = $source['url']; $data = getimgsize($source['path']); $imgw = $data[0]; $imgh = $data[1]; } else { $img = "{$global['webSiteRootURL']}view/img/audio_wave.jpg"; } $images = Video::getImageFromFilename($video['filename']); $poster = $images->poster; if (!empty($images->posterPortrait)) { $img = $images->posterPortrait; $data = getimgsize($source['path']); $imgw = $data[0]; $imgh = $data[1]; } require_once $global['systemRootPath'] . 'plugin/AVideoPlugin.php'; /* * Swap aspect ratio for rotated (vvs) videos if ($video['rotation'] === "90" || $video['rotation'] === "270") { $embedResponsiveClass = "embed-responsive-9by16"; $vjsClass = "vjs-9-16"; } else { $embedResponsiveClass = "embed-responsive-16by9"; $vjsClass = "vjs-16-9"; } */ $vjsClass = ""; $obj = new Video("", "", $video['id']); $resp = $obj->addView(); if (($video['type'] !== "audio") && ($video['type'] !== "linkAudio")) { $poster = "{$global['webSiteRootURL']}videos/{$video['filename']}.jpg"; } else { $poster = "{$global['webSiteRootURL']}view/img/audio_wave.jpg"; } //https://.../vEmbed/527?modestbranding=1&showinfo=0&autoplay=1&controls=0&loop=1&mute=1&t=0 $modestbranding = false; $autoplay = false; $controls = "controls"; $loop = ""; $mute = ""; $objectFit = ""; $t = 0; if (isset($_GET['modestbranding']) && $_GET['modestbranding'] == "1") { $modestbranding = true; } if (!empty($_GET['autoplay']) || $config->getAutoplay()) { $autoplay = true; } if (isset($_GET['controls']) && $_GET['controls'] == "0") { $controls = ""; } if (!empty($_GET['loop'])) { $loop = "loop"; } if (!empty($_GET['mute'])) { $mute = 'muted="muted"'; } if (!empty($_GET['objectFit'])) { $objectFit = 'object-fit: ' . $_GET['objectFit']; } if (!empty($_GET['t'])) { $t = intval($_GET['t']); } else if (!empty($video['progress']['lastVideoTime'])) { $t = intval($video['progress']['lastVideoTime']); } else if (!empty($video['externalOptions']->videoStartSeconds)) { $t = parseDurationToSeconds($video['externalOptions']->videoStartSeconds); }$sources = getVideosURLPDF($video['filename']); ?> <?php echo $config->getWebSiteTitle(); ?> :: <?php echo $video['title']; ?> " /> - getWebSiteTitle(); ?>" /> " />