diff --git a/objects/functions.php b/objects/functions.php index a1ba2404a9..37c2d9abd1 100644 --- a/objects/functions.php +++ b/objects/functions.php @@ -2010,9 +2010,9 @@ function make_path($path) { } if (!is_dir($path)) { //if(preg_match('/getvideoinfo/i', $path)){var_dump(debug_backtrace());} - if(preg_match('/cache/i', $path)){ + if (preg_match('/cache/i', $path)) { $mode = 0777; - }else{ + } else { $mode = 0755; } $created = mkdir($path, $mode, true); @@ -5646,14 +5646,14 @@ function forbiddenPage($message = '', $logMessage = false, $unlockPassword = '', break; } } - if(empty($unlockPassword) && preg_match('/json/i', $contentType)){ + if (empty($unlockPassword) && preg_match('/json/i', $contentType)) { header("Content-Type: application/json"); $obj = new stdClass(); $obj->error = true; $obj->msg = $message; $obj->forbiddenPage = true; die(json_encode($obj)); - }else{ + } else { header("Content-Type: text/html"); include $global['systemRootPath'] . 'view/forbiddenPage.php'; } @@ -6373,14 +6373,31 @@ function getSocialModal($videos_id, $url = "", $title = "") { function getCroppie( $buttonTitle, $callBackJSFunction, - $resultWidth, - $resultHeight, + $resultWidth = 0, + $resultHeight = 0, $viewportWidth = 0, $boundary = 25, $viewportHeight = 0, $enforceBoundary = true ) { global $global; + + if (empty($resultWidth) && empty($resultHeight)) { + if (isMobile()) { + $viewportWidth = 250; + } else { + $viewportWidth = 800; + } + + if (defaultIsPortrait()) { + $resultWidth = 540; + $resultHeight = 800; + } else { + $resultWidth = 1280; + $resultHeight = 720; + } + } + if (empty($viewportWidth)) { $viewportWidth = $resultWidth; } diff --git a/objects/subscribe.php b/objects/subscribe.php index 08a4c4b654..1adc342a55 100644 --- a/objects/subscribe.php +++ b/objects/subscribe.php @@ -292,7 +292,8 @@ class Subscribe $sql .= " AND users_id = '{$user_id}' "; } - $sql .= BootGrid::getSqlSearchFromPost(['email']); + //$sql .= BootGrid::getSqlSearchFromPost(['email']); + //echo $sql, '
', PHP_EOL; $res = sqlDAL::readSql($sql); $numRows = sqlDAL::num_rows($res); sqlDAL::close($res); @@ -357,7 +358,7 @@ class Subscribe if (!empty($advancedCustom->removeSubscribeButton)) { return ""; } - + $rowCount = getRowCount(); $total = static::getTotalSubscribes($user_id); $btnFile = $global['systemRootPath'] . 'view/subscribeBtnOffline.html'; diff --git a/objects/user.php b/objects/user.php index 7f009d1029..3301ea4672 100644 --- a/objects/user.php +++ b/objects/user.php @@ -1,5 +1,4 @@ addExternalOptions('ProfilePassword', preg_replace('/[^0-9a-z]/i', '', $value)); } + static function getChannelPanel($users_id) { + $u = new User($users_id); + $get = ['channelName' => $u->getChannelName()]; + ?> +
+
+ User Photo + + + + +
+ + +
+
+ + +
+ ' . getAdsLeaderBoardTop2() . ''; if (empty($_GET['catName'])) { $objLive = AVideoPlugin::getDataObject('Live'); - if(empty($objLive->doNotShowLiveOnVideosList)){ - ?> - - - - - - doNotShowLiveOnVideosList)) { + ?> + + + + + + +
+

+
+ '; + User::getChannelPanel($value['id']); + echo '
'; + } + reloadSearch(); + ?> +
+ + CategoriesShowOnlySuggested; cleanSearchVar(); $categories = Category::getAllCategories(false, true, $onlySuggested); - reloadSearchVar(); + reloadSearchVar(); foreach ($categories as $value) { $currentCat = $value['clean_name']; include $global['systemRootPath'] . 'plugin/Gallery/view/modeGalleryCategory.php'; } - }else{ + } else { include $global['systemRootPath'] . 'plugin/Gallery/view/modeGalleryCategory.php'; } } diff --git a/view/channels.php b/view/channels.php index cd07857232..20a1a7dcf7 100644 --- a/view/channels.php +++ b/view/channels.php @@ -102,45 +102,7 @@ $metaDescription = __("Channels"); $value['channelName']]; ?> -
-
- User Photo - - - - -
- - -
-
- - -
-