File: /home/httpd/html/baretube.com.new/admin/publish_content.php
<?php
include('db.php');
if(is_numeric($_GET['id'])) {
$id = (int)$_GET['id'];
dbQuery("UPDATE content SET enabled = 1, scheduled_date = NOW(), encoded_date = NOW() WHERE record_num = '$id'");
updateRelatedVideos($id);
updateContentSearch($id);
generateSlug($id);
if($randomViewsEnabled && is_numeric($randomViewsMin) && is_numeric($randomViewsMax)) {
$newViews = rand($randomViewsMin,$randomViewsMax);
dbQuery("UPDATE content_views SET views = '$newViews' WHERE content = '$id'");
}
}
header("Location: publish.php");
exit();
?>