1
0
Fork 0
mirror of https://github.com/DanielnetoDotCom/YouPHPTube synced 2025-10-03 17:59:55 +02:00
This commit is contained in:
daniel 2020-06-08 12:01:02 -03:00
parent 297f6307ab
commit 5e145f731d
10 changed files with 210 additions and 221 deletions

View file

@ -1,6 +1,9 @@
<?php
global $global;
if(empty($global['systemRootPath'])){
require_once '../../videos/configuration.php';
}
require_once $global['systemRootPath'] . 'plugin/Plugin.abstract.php';
class CustomizeUser extends PluginAbstract {
@ -38,7 +41,7 @@ class CustomizeUser extends PluginAbstract {
$obj->userCanNotChangeUserGroup = false;
$o = new stdClass();
$o->type = array(0=>_("Default"))+UserGroups::getAllUsersGroupsArray();
$o->type = array(0=>__("Default"))+UserGroups::getAllUsersGroupsArray();
$o->value = 0;
$obj->userDefaultUserGroup = $o;
$obj->userMustBeLoggedIn = !isset($advancedCustom->userMustBeLoggedIn) ? false : $advancedCustom->userMustBeLoggedIn;
@ -66,6 +69,7 @@ class CustomizeUser extends PluginAbstract {
$obj->showChannelHomeTab = true;
$obj->showChannelVideosTab = true;
$obj->showChannelProgramsTab = true;
$obj->showBigVideoOnChannelVideosTab = true;
$obj->encryptPasswordsWithSalt = !isset($advancedCustom->encryptPasswordsWithSalt) ? false : $advancedCustom->encryptPasswordsWithSalt;
$obj->requestCaptchaAfterLoginsAttempts = !isset($advancedCustom->requestCaptchaAfterLoginsAttempts) ? 0 : $advancedCustom->requestCaptchaAfterLoginsAttempts;
$obj->disableSignOutButton = false;

View file

@ -24,16 +24,14 @@ if ($obj->BigVideo && empty($_GET['showOnly'])) {
}
$_GET = $get;
?>
<div class="clear clearfix" id="bigVideo" style="background-color: rgb(<?php echo $obj->backgroundRGB; ?>);background: url(<?php echo $poster; ?>) no-repeat center center fixed; -webkit-background-size: cover;
<div class="row" id="bigVideo" style="background-color: rgb(<?php echo $obj->backgroundRGB; ?>);background: url(<?php echo $poster; ?>) no-repeat center center fixed; -webkit-background-size: cover;
-moz-background-size: cover;
-o-background-size: cover;
background-size: cover;
height: 0;
padding-bottom: 56.25%;/* Aspect ratio */
margin: -120px -20px;
margin-bottom: 0;
position: relative;
margin-bottom: <?php echo $obj->BigVideoMarginBottom; ?>;
position: relative;
z-index: 0;" >
<?php
if (!isMobile() && !empty($video['trailer1'])) {
@ -42,7 +40,7 @@ if ($obj->BigVideo && empty($_GET['showOnly'])) {
<iframe src="<?php echo parseVideos($video['trailer1'], 1, 1, 1, 0, 0, 'fill'); ?>" frameborder="0" allowtransparency="true" allow="autoplay"></iframe>
</div>
<div id="bg_container_overlay" ></div>
<div class="posterDetails " style=" padding: 30px; padding-top: 120px;
<div class="posterDetails " style=" padding: 30px;
background: -webkit-linear-gradient(bottom, rgba(<?php echo $obj->backgroundRGB; ?>,1) 2%, rgba(<?php echo $obj->backgroundRGB; ?>,0) 100%);
background: -o-linear-gradient(top, rgba(<?php echo $obj->backgroundRGB; ?>,1) 2%, rgba(<?php echo $obj->backgroundRGB; ?>,0) 100%);
background: linear-gradient(top, rgba(<?php echo $obj->backgroundRGB; ?>,1) 2%, rgba(<?php echo $obj->backgroundRGB; ?>,0) 100%);
@ -50,7 +48,7 @@ if ($obj->BigVideo && empty($_GET['showOnly'])) {
<?php
} else {
?>
<div class="posterDetails " style=" padding: 30px; padding-top: 120px;
<div class="posterDetails " style=" padding: 30px;
background: -webkit-linear-gradient(left, rgba(<?php echo $obj->backgroundRGB; ?>,1) 40%, rgba(<?php echo $obj->backgroundRGB; ?>,0) 100%);
background: -o-linear-gradient(right, rgba(<?php echo $obj->backgroundRGB; ?>,1) 40%, rgba(<?php echo $obj->backgroundRGB; ?>,0) 100%);
background: linear-gradient(right, rgba(<?php echo $obj->backgroundRGB; ?>,1) 40%, rgba(<?php echo $obj->backgroundRGB; ?>,0) 100%);
@ -113,9 +111,9 @@ if ($obj->BigVideo && empty($_GET['showOnly'])) {
</h4>
<div class="row">
<?php
$colClass = "col-md-2 col-sm-4 col-xs-6";
$colClass = "col-md-4 col-sm-6 col-xs-6";
if (!empty($obj->RemoveBigVideoDescription)) {
$colClass = "col-md-4 col-sm-4 col-xs-6";
$colClass = "col-md-4 col-sm-6 col-xs-6";
}
if (empty($obj->landscapePosters) && !empty($images->posterPortrait)) {
?>
@ -128,7 +126,7 @@ if ($obj->BigVideo && empty($_GET['showOnly'])) {
<div class="<?php echo $colClass; ?>">
<a href="<?php echo YouPHPFlix2::getLinkToVideo($video['id']); ?>">
<div class="thumbsImage">
<img alt="<?php echo $video['title']; ?>" class="img img-responsive posterPortrait thumbsJPG" src="<?php echo $images->poster; ?>" style="min-width: 135px; height: auto;" />
<img alt="<?php echo $video['title']; ?>" class="img img-responsive posterPortrait thumbsJPG" src="<?php echo $images->poster; ?>" />
<?php if (!empty($images->thumbsGif)) { ?>
<img style="position: absolute; top: 0; display: none;" src="<?php echo $images->thumbsGif; ?>" alt="<?php echo $video['title']; ?>" id="thumbsGIFBig<?php echo $video['id']; ?>" class="thumbsGIF img-responsive img" />
<?php } ?>

View file

@ -286,7 +286,7 @@ footer .btn-outline {
height: 210px;
}
#bigVideo .posterPortrait {
height: 30vh;
height: auto;
}
#bigVideo .mainInfoText{
max-height: 29vh;
@ -323,6 +323,9 @@ footer .btn-outline {
#carouselRows h2{
position: relative;
}
#carouselRows{
margin-top: -20%;
}
body.fullscreen{
margin: 0;
@ -350,11 +353,6 @@ body.fullscreen{
overflow: hidden;
height: 450px !important;
}
#bigVideo .posterPortrait {
height: 20vh;
min-height: 193px;
min-width: 135px !important;
}
}
.paidOnlyLabel{
position: absolute;

View file

@ -17,5 +17,6 @@
TimeLogEnd($timeLog, __LINE__);
?>
</div>
<script src="<?php echo $global['webSiteRootURL']; ?>view/js/infinite-scroll.pkgd.min.js" type="text/javascript"></script>
<script src="<?php echo $global['webSiteRootURL']; ?>plugin/Gallery/script.js" type="text/javascript"></script>
<script src="<?php echo $jsURL; ?>" type="text/javascript"></script>

View file

@ -1,3 +1,2 @@
<link href="<?php echo $global['webSiteRootURL']; ?>view/js/webui-popover/jquery.webui-popover.min.css" rel="stylesheet" type="text/css" />
<link href="<?php echo $global['webSiteRootURL']; ?>plugin/YouPHPFlix2/view/js/flickity/flickity.min.css" rel="stylesheet" type="text/css" />
<script src="<?php echo $global['webSiteRootURL']; ?>view/js/infinite-scroll.pkgd.min.js" type="text/javascript"></script>
<link href="<?php echo $global['webSiteRootURL']; ?>plugin/YouPHPFlix2/view/js/flickity/flickity.min.css" rel="stylesheet" type="text/css" />

View file

@ -98,7 +98,7 @@ TimeLogEnd($timeLog, __LINE__);
}
if ($advancedCustomUser->showChannelProgramsTab && !empty($palyListsObj)) {
?>
<li class="nav-item <?php echo $active; ?>">
<li class="nav-item <?php echo $active; ?>" id="channelPlayListsLi">
<a class="nav-link " href="#channelPlayLists" data-toggle="tab" aria-expanded="true">
<?php echo strtoupper(__("Playlists")); ?>
</a>
@ -114,7 +114,7 @@ TimeLogEnd($timeLog, __LINE__);
if ($advancedCustomUser->showChannelHomeTab) {
?>
<div class="tab-pane <?php echo $active; ?>" id="channelHome" style="min-height: 800px;">
<div class="container-fluid modeFlixContainer">
<div class="container-fluid modeFlixContainer" style="padding: 15px;">
<?php
$obj = AVideoPlugin::getObjectData("YouPHPFlix2");
$obj->BigVideo = true;
@ -131,6 +131,7 @@ TimeLogEnd($timeLog, __LINE__);
$obj->Categories = false;
$obj->playVideoOnFullscreen = false;
$obj->titleLabel = true;
$obj->RemoveBigVideoDescription = true;
include $global['systemRootPath'] . 'plugin/YouPHPFlix2/view/modeFlixBody.php';
?>
@ -163,7 +164,7 @@ TimeLogEnd($timeLog, __LINE__);
</div>
<div class="panel-body">
<?php
if (!empty($uploadedVideos[0])) {
if ($advancedCustomUser->showBigVideoOnChannelVideosTab && !empty($uploadedVideos[0])) {
$video = $uploadedVideos[0];
$obj = new stdClass();
$obj->BigVideo = true;

View file

@ -8,9 +8,6 @@ include $global['systemRootPath'] . 'plugin/YouPHPFlix2/view/modeFlixHead.php';
.galleryVideo {
padding-bottom: 10px;
}
#bigVideo{
margin: 0 0 -350px 0!important;
}
#bigVideoCarousel{
height: auto;
}
@ -20,12 +17,6 @@ include $global['systemRootPath'] . 'plugin/YouPHPFlix2/view/modeFlixHead.php';
.modeFlixContainer{
padding: 0;
}
#carouselRows, .modeFlixContainer .carousel {
min-height: 300px;
}
#carouselRows, .modeFlixContainer .poster {
margin-top: 25px;
}
.topicRow{
margin: 0;
}

View file

@ -1,4 +1,9 @@
<div class="programsContainerItem">
<style>
#channelPlayListsLi{
display: block !important;
}
</style>
<?php
global $global, $config, $isChannel;
$isChannel = 1; // still workaround, for gallery-functions, please let it there.
@ -114,7 +119,7 @@
if ($playlist['status'] != "favorite" && $playlist['status'] != "watch_later") {
if (AVideoPlugin::isEnabledByName("PlayLists")) {
?>
<button class="btn btn-xs btn-default" onclick="copyToClipboard($('#playListEmbedCode<?php echo $playlist['id']; ?>').val());setTextEmbedCopied();" ><span class="fa fa-copy"></span> <span id="btnEmbedText"><?php echo __("Copy embed code"); ?></span></button>
<button class="btn btn-xs btn-default" onclick="copyToClipboard($('#playListEmbedCode<?php echo $playlist['id']; ?>').val()); setTextEmbedCopied();" ><span class="fa fa-copy"></span> <span id="btnEmbedText"><?php echo __("Copy embed code"); ?></span></button>
<input type="hidden" id="playListEmbedCode<?php echo $playlist['id']; ?>" value='<?php
$code = str_replace("{embedURL}", "{$global['webSiteRootURL']}plugin/PlayLists/embed.php?playlists_id={$playlist['id']}", $advancedCustom->embedCodeTemplate);
echo ($code);
@ -141,13 +146,13 @@
</div><!-- /.modal -->
<script>
$(function () {
$('.seriePlaylist').click(function () {
$($('#seriePlaylistModal').find('iframe')[0]).attr('src', 'about:blank');
var playlist_id = $(this).attr('playlist_id');
$($('#seriePlaylistModal').find('iframe')[0]).attr('src', '<?php echo $global['webSiteRootURL']; ?>plugin/PlayLists/playListToSerie.php?playlist_id=' + playlist_id);
$('#seriePlaylistModal').modal();
//$('#seriePlaylistModal').modal('hide');
});
$('.seriePlaylist').click(function () {
$($('#seriePlaylistModal').find('iframe')[0]).attr('src', 'about:blank');
var playlist_id = $(this).attr('playlist_id');
$($('#seriePlaylistModal').find('iframe')[0]).attr('src', '<?php echo $global['webSiteRootURL']; ?>plugin/PlayLists/playListToSerie.php?playlist_id=' + playlist_id);
$('#seriePlaylistModal').modal();
//$('#seriePlaylistModal').modal('hide');
});
});
</script>
@ -231,18 +236,18 @@
<?php
if (!empty($serie['trailer1'])) {
?>
<a href="#" class="btn btn-xs btn-warning" onclick="$(this).removeAttr('href');$('#serie<?php echo $serie['id']; ?> img').fadeOut();$('<iframe>', {
src: '<?php echo parseVideos($serie['trailer1'], 1, 0, 0, 0, 1, 0, 'fill'); ?>',
id: 'myFrame<?php echo $serie['id']; ?>',
allow: 'autoplay',
frameborder: 0,
height: 200,
width: '100%',
scrolling: 'no'
}).appendTo('#serie<?php echo $serie['id']; ?>');
$(this).removeAttr('onclick');
$(this).fadeOut();
return false;">
<a href="#" class="btn btn-xs btn-warning" onclick="$(this).removeAttr('href'); $('#serie<?php echo $serie['id']; ?> img').fadeOut(); $('<iframe>', {
src: '<?php echo parseVideos($serie['trailer1'], 1, 0, 0, 0, 1, 0, 'fill'); ?>',
id: 'myFrame<?php echo $serie['id']; ?>',
allow: 'autoplay',
frameborder: 0,
height: 200,
width: '100%',
scrolling: 'no'
}).appendTo('#serie<?php echo $serie['id']; ?>');
$(this).removeAttr('onclick');
$(this).fadeOut();
return false;">
<span class="fa fa-film"></span>
<span class="hidden-xs"><?php echo __("Trailer"); ?></span>
</a>
@ -311,19 +316,19 @@
}
?>
<button onclick="addVideoToPlayList(<?php echo $value['id']; ?>, false, <?php echo $value['watchLaterId']; ?>);return false;" class="btn btn-dark btn-xs watchLaterBtnAdded watchLaterBtnAdded<?php echo $value['id']; ?>" title="<?php echo __("Added On Watch Later"); ?>" style="color: #4285f4;<?php echo $watchLaterBtnAddedStyle; ?>" ><i class="fas fa-check"></i></button>
<button onclick="addVideoToPlayList(<?php echo $value['id']; ?>, false, <?php echo $value['watchLaterId']; ?>); return false;" class="btn btn-dark btn-xs watchLaterBtnAdded watchLaterBtnAdded<?php echo $value['id']; ?>" title="<?php echo __("Added On Watch Later"); ?>" style="color: #4285f4;<?php echo $watchLaterBtnAddedStyle; ?>" ><i class="fas fa-check"></i></button>
<button onclick="addVideoToPlayList(<?php echo $value['id']; ?>, true, <?php echo $value['watchLaterId']; ?>);
return false;" class="btn btn-dark btn-xs watchLaterBtn watchLaterBtn<?php echo $value['id']; ?>" title="<?php echo __("Watch Later"); ?>" style="<?php echo $watchLaterBtnStyle; ?>" ><i class="fas fa-clock"></i></button>
return false;" class="btn btn-dark btn-xs watchLaterBtn watchLaterBtn<?php echo $value['id']; ?>" title="<?php echo __("Watch Later"); ?>" style="<?php echo $watchLaterBtnStyle; ?>" ><i class="fas fa-clock"></i></button>
<br>
<button onclick="addVideoToPlayList(<?php echo $value['id']; ?>, false, <?php echo $value['favoriteId']; ?>);
return false;" class="btn btn-dark btn-xs favoriteBtnAdded favoriteBtnAdded<?php echo $value['id']; ?>" title="<?php echo __("Added On Favorite"); ?>" style="color: #4285f4; <?php echo $favoriteBtnAddedStyle; ?>"><i class="fas fa-check"></i></button>
return false;" class="btn btn-dark btn-xs favoriteBtnAdded favoriteBtnAdded<?php echo $value['id']; ?>" title="<?php echo __("Added On Favorite"); ?>" style="color: #4285f4; <?php echo $favoriteBtnAddedStyle; ?>"><i class="fas fa-check"></i></button>
<button onclick="addVideoToPlayList(<?php echo $value['id']; ?>, true, <?php echo $value['favoriteId']; ?>);
return false;" class="btn btn-dark btn-xs favoriteBtn favoriteBtn<?php echo $value['id']; ?>" title="<?php echo __("Favorite"); ?>" style="<?php echo $favoriteBtnStyle; ?>" ><i class="fas fa-heart" ></i></button>
return false;" class="btn btn-dark btn-xs favoriteBtn favoriteBtn<?php echo $value['id']; ?>" title="<?php echo __("Favorite"); ?>" style="<?php echo $favoriteBtnStyle; ?>" ><i class="fas fa-heart" ></i></button>
</div>
<?php
}
?>
<?php
}
?>
</a>
<a class="hrefLink" href="<?php echo $episodeLink; ?>" title="<?php echo $value['title']; ?>">
<h2><?php echo $value['title']; ?></h2>
@ -341,34 +346,34 @@
}
?>
</div>
<?php
if (empty($advancedCustom->doNotDisplayViews)) {
?>
<?php
if (empty($advancedCustom->doNotDisplayViews)) {
?>
<div>
<i class="fa fa-eye"></i>
<span itemprop="interactionCount">
<?php echo number_format($value['views_count'], 0); ?> <?php echo __("Views"); ?>
<?php echo number_format($value['views_count'], 0); ?> <?php echo __("Views"); ?>
</span>
</div>
<?php
}
?>
<?php
}
?>
<div>
<i class="far fa-clock"></i>
<?php
echo humanTiming(strtotime($value['videoCreation'])), " ", __('ago');
?>
<?php
echo humanTiming(strtotime($value['videoCreation'])), " ", __('ago');
?>
</div>
<div>
<i class="fa fa-user"></i>
<?php
echo $name;
?>
<?php
echo $name;
?>
</div>
<?php
if (Video::canEdit($value['id'])) {
?>
<?php
if (Video::canEdit($value['id'])) {
?>
<div>
<a href="<?php echo $global['webSiteRootURL']; ?>mvideos?video_id=<?php echo $value['id']; ?>" class="text-primary"><i class="fa fa-edit"></i> <?php echo __("Edit Video"); ?></a>
@ -377,27 +382,27 @@
<?php
}
?>
<?php
if ($isMyChannel) {
?>
<?php
if ($isMyChannel) {
?>
<div>
<span style=" cursor: pointer;" class="btn-link text-primary removeVideo" playlist_id="<?php echo $playlist['id']; ?>" video_id="<?php echo $value['id']; ?>">
<i class="fa fa-trash"></i> <?php echo __("Remove"); ?>
</span>
</div>
<?php
}
?>
</div>
</div>
<?php
}
?>
</div>
<?php
}
?>
</div>
</div>
<?php
}
?>
</div>
<?php
}
?>
</div>
<?php
@ -412,150 +417,138 @@
<script>
$(function () {
$('.removeVideo').click(function () {
currentObject = this;
$('.removeVideo').click(function () {
currentObject = this;
swal({
title: "<?php echo __("Are you sure?"); ?>",
text: "<?php echo __("You will not be able to recover this action!"); ?>",
icon: "warning",
buttons: true,
dangerMode: true,
})
.then((willDelete) = > {
if (willDelete) {
swal({
title: "<?php echo __("Are you sure?"); ?>",
text: "<?php echo __("You will not be able to recover this action!"); ?>",
icon: "warning",
buttons: true,
dangerMode: true,
})
.then((willDelete) => {
if (willDelete) {
modal.showPleaseWait();
var playlist_id = $(currentObject).attr('playlist_id');
var video_id = $(currentObject).attr('video_id');
$.ajax({
url: '<?php echo $global['webSiteRootURL']; ?>objects/playlistRemoveVideo.php',
data: {
"playlist_id": playlist_id,
"video_id": video_id
},
type: 'post',
success: function (response) {
reloadPlayLists();
$(".playListsIds" + video_id).prop("checked", false);
$(currentObject).closest('.galleryVideo').fadeOut();
modal.hidePleaseWait();
}
});
}
});
});
$('.deletePlaylist').click(function () {
currentObject = this;
swal({
title: "<?php echo __("Are you sure?"); ?>",
text: "<?php echo __("You will not be able to recover this action!"); ?>",
icon: "warning",
buttons: true,
dangerMode: true,
})
.then((willDelete) => {
if (willDelete) {
modal.showPleaseWait();
var playlist_id = $(currentObject).attr('playlist_id');
console.log(playlist_id);
$.ajax({
url: '<?php echo $global['webSiteRootURL']; ?>objects/playlistRemove.php',
data: {
"playlist_id": playlist_id
},
type: 'post',
success: function (response) {
$(currentObject).closest('.panel').slideUp();
modal.hidePleaseWait();
}
});
}
});
});
$('.statusPlaylist').click(function () {
var playlist_id = $(this).attr('playlist_id');
var status = "public";
if ($('#statusPrivate' + playlist_id).is(":visible")) {
status = "public";
$('.statusPlaylist' + playlist_id + ' span').hide();
$('#statusPublic' + playlist_id).fadeIn();
} else if ($('#statusPublic' + playlist_id).is(":visible")) {
status = "unlisted";
$('.statusPlaylist' + playlist_id + ' span').hide();
$('#statusUnlisted' + playlist_id).fadeIn();
} else if ($('#statusUnlisted' + playlist_id).is(":visible")) {
status = "private";
$('.statusPlaylist' + playlist_id + ' span').hide();
$('#statusPrivate' + playlist_id).fadeIn();
}
modal.showPleaseWait();
console.log(playlist_id);
var playlist_id = $(currentObject).attr('playlist_id');
var video_id = $(currentObject).attr('video_id');
$.ajax({
url: '<?php echo $global['webSiteRootURL']; ?>objects/playlistStatus.php',
data: {
"playlist_id": playlist_id,
"status": status
},
type: 'post',
success: function (response) {
modal.hidePleaseWait();
}
});
});
$('.renamePlaylist').click(function () {
currentObject = this;
swal({
title: "<?php echo __("Change Playlist Name"); ?>!",
text: "<?php echo __("What is the new name?"); ?>",
content: "input",
showCancelButton: true,
closeOnConfirm: true,
inputPlaceholder: "<?php echo __("Playlist name?"); ?>"
}).then(inputValue => {
if (!inputValue || inputValue === false || inputValue === "")
return false;
modal.showPleaseWait();
var playlist_id = $(currentObject).attr('playlist_id');
console.log(playlist_id);
$.ajax({
url: '<?php echo $global['webSiteRootURL']; ?>objects/playlistRename.php',
url: '<?php echo $global['webSiteRootURL']; ?>objects/playlistRemoveVideo.php',
data: {
"playlist_id": playlist_id,
"name": inputValue
"playlist_id": playlist_id,
"video_id": video_id
},
type: 'post',
success: function (response) {
$(currentObject).closest('.panel').find('.playlistName').text(inputValue);
modal.hidePleaseWait();
reloadPlayLists();
$(".playListsIds" + video_id).prop("checked", false);
$(currentObject).closest('.galleryVideo').fadeOut();
modal.hidePleaseWait();
}
});
return false;
});
});
$('.sortNow').click(function () {
var $val = $(this).siblings("input").val();
sortNow(this, $val);
});
$('.video_order').keypress(function (e) {
if (e.which == 13) {
sortNow(this, $(this).val());
}
});
});
});
$('.deletePlaylist').click(function () {
currentObject = this;
swal({
title: "<?php echo __("Are you sure?"); ?>",
text: "<?php echo __("You will not be able to recover this action!"); ?>",
icon: "warning",
buttons: true,
dangerMode: true,
})
.then((willDelete) = > {
if (willDelete) {
modal.showPleaseWait();
var playlist_id = $(currentObject).attr('playlist_id');
console.log(playlist_id);
$.ajax({
url: '<?php echo $global['webSiteRootURL']; ?>objects/playlistRemove.php',
data: {
"playlist_id": playlist_id
},
type: 'post',
success: function (response) {
$(currentObject).closest('.panel').slideUp();
modal.hidePleaseWait();
}
});
}
});
});
$('.statusPlaylist').click(function () {
var playlist_id = $(this).attr('playlist_id');
var status = "public";
if ($('#statusPrivate' + playlist_id).is(":visible")) {
status = "public";
$('.statusPlaylist' + playlist_id + ' span').hide();
$('#statusPublic' + playlist_id).fadeIn();
} else if ($('#statusPublic' + playlist_id).is(":visible")) {
status = "unlisted";
$('.statusPlaylist' + playlist_id + ' span').hide();
$('#statusUnlisted' + playlist_id).fadeIn();
} else if ($('#statusUnlisted' + playlist_id).is(":visible")) {
status = "private";
$('.statusPlaylist' + playlist_id + ' span').hide();
$('#statusPrivate' + playlist_id).fadeIn();
}
modal.showPleaseWait();
console.log(playlist_id);
$.ajax({
url: '<?php echo $global['webSiteRootURL']; ?>objects/playlistStatus.php',
data: {
"playlist_id": playlist_id,
"status": status
},
type: 'post',
success: function (response) {
modal.hidePleaseWait();
}
});
});
$('.renamePlaylist').click(function () {
currentObject = this;
swal({
title: "<?php echo __("Change Playlist Name"); ?>!",
text: "<?php echo __("What is the new name?"); ?>",
content: "input",
showCancelButton: true,
closeOnConfirm: true,
inputPlaceholder: "<?php echo __("Playlist name?"); ?>"
}).then(inputValue = > {
if (!inputValue || inputValue === false || inputValue === "")
return false;
modal.showPleaseWait();
var playlist_id = $(currentObject).attr('playlist_id');
console.log(playlist_id);
$.ajax({
url: '<?php echo $global['webSiteRootURL']; ?>objects/playlistRename.php',
data: {
"playlist_id": playlist_id,
"name": inputValue
},
type: 'post',
success: function (response) {
$(currentObject).closest('.panel').find('.playlistName').text(inputValue);
modal.hidePleaseWait();
}
});
return false;
});
});
$('.sortNow').click(function () {
var $val = $(this).siblings("input").val();
sortNow(this, $val);
});
$('.video_order').keypress(function (e) {
if (e.which == 13) {
sortNow(this, $(this).val());
}
});
});
</script>
<!--

View file

@ -110,7 +110,7 @@ $playListsObj = AVideoPlugin::getObjectData("PlayLists");
<a href="<?php echo $link; ?>" class="btn btn-xs btn-default playAll hrefLink" ><span class="fa fa-play"></span> <?php echo __("Play All"); ?></a><?php echo $playListButtons; ?>
<?php
$liveLink = PlayLists::getLiveLink($program['id']);
if(false && !empty($liveLink)){
if(!empty($liveLink)){
?>
<a href="<?php echo $liveLink; ?>" class="btn btn-xs btn-default playAll hrefLink" ><i class="fas fa-broadcast-tower"></i> <?php echo __("Play Live"); ?></a>
<?php

View file

@ -2,7 +2,8 @@
if(empty($mysqlHost)){
die();
}
_error_log("ERROR: your site is offline");
error_log("ERROR: your site is offline we could not connect into MySQL");
error_log("ERROR: used credentials: mysqlHost = $mysqlHost; mysqlUser = $mysqlUser; mysqlPass = $mysqlPass; mysqlDatabase = $mysqlDatabase;");
?>
<!doctype html>
<title>Site Maintenance</title>
@ -16,6 +17,9 @@ _error_log("ERROR: your site is offline");
</style>
<article>
<center>
<img src="videos/userPhoto/logo.png"/>
</center>
<h1>We&rsquo;ll be back soon!</h1>
<div>
<p>Sorry for the inconvenience but we&rsquo;re performing some maintenance at the moment.</p>