} //promote video if (isset($_POST['promote']) && isset($_POST['promote'])) { //delete each posted video foreach ($_POST['list'] as $video_id) { managevideo($video_id, 'promote'); } //notifications $show_notification = 1; $message = notifications(1); } //Un-promote video if (isset($_POST['unpromote']) && isset($_POST['unpromote'])) { //delete each posted video foreach ($_POST['list'] as $video_id) { managevideo($video_id, 'unpromote'); } //notifications $show_notification = 1; $message = notifications(1); } //Display Results >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> //pagination first ///////////////// if ($show_t == 1) { //active videos $pagination = pagination("SELECT * FROM videos WHERE approved='yes' {$sort}", $limit); } if ($show_t == 2) { //Video approval $pagination = pagination("SELECT * FROM videos WHERE approved='pending' {$sort}", $limit);
if ($contentid == '' || $type == '') { ErrorDisplay1($config["invalid_request"]); die; } //__________________________________________________________________________________________________________________ //________Check type and take action________________________________________________________________________________ if (isset($_POST['submit'])) { $show_table = ''; //so no table/submit form is shown after this process switch ($type) { //Videos case 1: $usercheck = new LoadPermissions('', $contentid, 'videos'); $usercheck->CheckPermissions(); $usercheck->ActionsCheck('delete'); managevideo($contentid, 'delete'); break; //Images //Images case 2: $usercheck = new LoadPermissions('', $contentid, 'images'); $usercheck->CheckPermissions(); $usercheck->ActionsCheck('delete'); manageimages($contentid, 'delete'); break; //Blogs (actual blog) //Blogs (actual blog) case 3: $usercheck = new LoadPermissions('', $contentid, 'blogs'); $usercheck->CheckPermissions(); $usercheck->ActionsCheck('delete');