require_once "admin_conn.php"; require_once "../inc/pinyin.php"; chkLogin(); $action = be("all", "action"); $_SESSION["upfolder"] = "../upload/art"; switch ($action) { case "add": case "edit": headAdmin("文章管理"); info(); break; case "save": save(); break; default: headAdmin("文章管理"); main(); break; } dispseObj(); function save() { global $db; $a_id = be("post", "a_id"); $a_title = be("post", "a_title"); $a_subtitle = be("post", "a_subtitle"); $a_entitle = be("post", "a_entitle"); $a_type = be("post", "a_type"); $a_content = be("post", "a_content"); $a_author = be("post", "a_author"); $a_color = be("post", "a_color");
switch (trim($action)) { case "login": login(); break; case "check": checkLogin(); break; case "logout": logout(); break; case "go": gourl(); break; case "wel": chkLogin(); headAdmin("欢迎页面"); wel(); break; default: chkLogin(); main(); break; } dispseObj(); function gourl() { $url = be("get", "url"); if ($url != "") { if (strpos($url, ".") < 1) { $url .= ".php"; }
<?php require_once "admin_conn.php"; require_once "./collect/collect_vod_program_item.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "editall": editall(); break; case "collecProgram": collecProgram(); break; default: headAdmin("电视直播管理"); main(); break; } dispseObj(); function collecProgram() { global $db, $cache; $tv_id = be("all", "tv_id"); if (!isNum($tv_id)) { echo '参数非法。'; } else { $tv_id = intval($tv_id); $row = $db->getRow("SELECT tv_id, tv_code, tv_playfrom FROM mac_tv_egp_config where tv_id=" . $tv_id . ' GROUP BY tv_id order by tv_playfrom asc'); //var_dump($row); if ($row) { $day = be("all", "day");
<?php require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); headAdmin("会员管理"); main(); dispseObj(); function main() { global $db; $pagenum = be("all", "page"); $group = be("get", "group"); if (!isNum($pagenum)) { $pagenum = 1; } else { $pagenum = intval($pagenum); } if ($pagenum < 1) { $pagenum = 1; } if (!isN($group)) { $where = " where u_group = " . $group; } $sql = "SELECT count(*) FROM {pre}user " . $where; $nums = $db->getOne($sql); $pagecount = ceil($nums / app_pagenum); $sql = "SELECT u_id,u_name,u_group,u_qq,u_email,u_status,u_points,u_tj,u_loginnum,u_logintime,u_ip,u_flag FROM {pre}user "; $sql .= $where . " ORDER BY u_id DESC limit " . app_pagenum * ($pagenum - 1) . "," . app_pagenum; $rs = $db->query($sql); ?>
<?php require_once "admin_conn.php"; require_once "genTopRecommendItems.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "editall": editall(); break; default: headAdmin("视频榜单管理"); main(); break; } dispseObj(); function editall() { global $db; $t_id = be("arr", "ids"); $ids = explode(",", $t_id); foreach ($ids as $id) { $t_flag = be("post", "t_flag" . $id); $t_sort = be("post", "disp_order" . $id); if (isN($t_sort)) { $t_sort = $db->getOne("SELECT MAX(disp_order) FROM {pre}vod_topic_items") + 1; } if (!isNum($t_sort)) { echo "信息填写不完整!"; exit; }
<?php require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "chgpwd": headAdmin("修改密码"); chgpwd(); break; default: headAdmin("修改密码"); main(); break; } dispseObj(); function chgpwd() { global $db; $oldP = be('all', 'old_pwds'); $newP = be('all', 'new_pwd'); $m_name = getCookie("adminname"); $row = $db->getRow("select m_id from {pre}manager where m_password='******' and m_name='" . $m_name . "'"); if (!isN($row['m_id'])) { $db->Update("{pre}manager", array('m_password'), array(md5($newP)), "m_name='" . $m_name . "'"); echo '更新密码成功'; } else { echo '输入的旧密码不对'; } } function main()
$updatelog = "bak/update.xml"; $verstr = getPage($updateserver . "?v=" . version, "utf-8"); $adpath = $_SERVER["SCRIPT_NAME"]; $adpath = substring($adpath, strripos($adpath, "/")); $n = strripos($adpath, "/"); $adpath = substring($adpath, strlen($adpath) - $n, $n + 1) . "/"; switch ($action) { case "checkversion": checkversion(); break; case "showfilelist": headAdmin("更新列表"); showfilelist(); break; case "showfile": headAdmin("更新列表"); showfile(); break; } dispseObj(); function checkversion() { global $verstr; if (strpos($verstr, "</joyplus>") > 0) { $doc = new DOMDocument(); $doc->formatOutput = true; $doc->loadxml($verstr); $xmlnode = $doc->documentElement; $serverversion = $xmlnode->getElementsByTagName("version")->item(0)->nodeValue; $vardec = $xmlnode->getElementsByTagName("des")->item(0)->nodeValue; unset($xmlnode);
require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "editall": editall(); break; case "import": import(); break; case "info": headAdmin("节目类别管理"); info(); break; default: headAdmin("节目类别管理"); main(); break; } dispseObj(); function import() { global $db; if ($_FILES["file"]["error"] > 0) { echo "Error: " . $_FILES["file"]["error"] . "<br />"; } else { $file = $_FILES["file"]["tmp_name"]; $tempFile = $_FILES["file"]["name"]; if (!isN($tempFile) && strpos($tempFile, ".csv") !== false && strpos($tempFile, ".csv") === strlen($tempFile) - 4) { try { $str = file_get_contents($file);
<?php require_once "admin_conn.php"; chkLogin(); headAdmin("定时任务设置"); $xmlpath = "../inc/timmingset.xml"; $doc = new DOMDocument(); $doc->formatOutput = true; $doc->load($xmlpath); $xmlnode = $doc->documentElement; $nodes = $xmlnode->getElementsByTagName("timming"); ?> <script language="javascript"> $(document).ready(function(){ var app_timming=<?php echo app_timming; ?> ; $("#form1").validate({ rules:{ name:{ required:true, stringCheck:true, maxlength:40 }, des:{ required:true, stringCheck:true, maxlength:40 }, file:{
<?php require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "editall": editall(); break; default: headAdmin("文章专题管理"); main(); break; } dispseObj(); function editall() { global $db; $t_id = be("arr", "t_id"); $ids = explode(",", $t_id); foreach ($ids as $id) { $t_name = be("post", "t_name" . $id); $t_sort = be("post", "t_sort" . $id); $t_enname = be("post", "t_enname" . $id); $t_template = be("post", "t_template" . $id); $t_pic = be("post", "t_pic" . $id); if (isN($t_name)) { echo "信息填写不完整!"; exit; } if (isN($t_enname)) {
delall(); break; case "compress": compress(); break; case "bak": bak(); break; case "repair": repair(); break; case "getsize": getsize(); break; default: headAdmin("数据库管理"); main(); break; } dispseObj(); function make_header($table) { global $db; $sql = "DROP TABLE IF EXISTS " . $table . "\n"; $row = $db->getRow("show create table " . $table); $tmp = preg_replace("/\n/", "", $row["Create Table"]); $sql .= $tmp . "\n"; unset($row); return $sql; } function make_manager($table)
<?php require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "editall": editall(); break; case "info": headAdmin("云推推渠道管理"); info(); break; default: headAdmin("云推推渠道管理"); main(); break; } dispseObj(); function editall() { global $db; $t_id = be("arr", "t_id"); $ids = explode(",", $t_id); foreach ($ids as $id) { $tv_playfrom = be("post", "tv_playfrom" . $id); $tv_definition = be("post", "tv_definition" . $id); $tv_playurl = be("post", "tv_playurl" . $id); //var_dump($t_type); $status = be("post", "status" . $id); if (isN($tv_playurl)) {
<?php require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "audit": audit(); break; default: headAdmin("留言管理"); main(); break; } dispseObj(); function audit() { global $db; $g_id = be("arr", "g_id"); if (!isN($g_id)) { $db->Update("{pre}gbook", array("g_audit"), array("1"), "g_id in (" . $g_id . ")"); } echo "审核完毕"; } function main() { global $db; $pagenum = be("all", "page"); if (!isNum($pagenum)) { $pagenum = 1; } else {
<?php require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); headAdmin("用户组管理"); main(); dispseObj(); function main() { global $db; $pagenum = be("all", "page"); if (!isNum($pagenum)) { $pagenum = 1; } else { $pagenum = intval($pagenum); } if ($pagenum < 1) { $pagenum = 1; } $sql = "SELECT count(*) FROM {pre}user_group"; $nums = $db->getOne($sql); $pagecount = ceil($nums / app_pagenum); $sql = "SELECT ug_id,ug_name,ug_type,ug_popedom,ug_upgrade,ug_popvalue FROM {pre}user_group ORDER BY ug_popvalue DESC limit " . app_pagenum * ($pagenum - 1) . "," . app_pagenum; $rs = $db->query($sql); ?> <script language="javascript"> $(document).ready(function(){ $("#form2").validate({ rules:{ ug_name:{
break; case "save": save(); break; case "del": del(); break; case "tj": headAdmin("统计代码管理"); tj(); break; case "tjsave": tjsave(); break; default: headAdmin("广告管理"); main(); break; } dispseObj(); function save() { $file = be("post", "file"); $filecontent = stripslashes(be("post", "filecontent")); fwrite(fopen("../template/" . app_templatedir . "/ads/" . $file . ".js", "wb"), $filecontent); echo "保存完毕"; } function del() { $fpath = "../template/" . app_templatedir . "/ads/"; $file = be("get", "file");
require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "editall": editall(); break; case "last": moveTolast(); break; case "next": moveTonext(); break; default: headAdmin("友情链接管理"); main(); break; } dispseObj(); function editall() { global $db; $l_id = be("arr", "l_id"); $ids = explode(",", $l_id); foreach ($ids as $id) { $l_name = be("post", "l_name" . $id); $l_sort = be("post", "l_sort" . $id); $l_url = be("post", "l_url" . $id); if (isN($l_name)) { echo "名称不能为空";
<?php require_once "admin_conn.php"; $command = '* * * * * root wget http://cmsdev.joyplus.tv/manager/collect/auto_collect_vod_cj.php?p_id=7_1-6'; // replaceCommand($command,'p_id=6_1-6'); $action = be("all", "action"); switch ($action) { default: headAdmin("定时器管理"); main(); break; } function newCommand($command) { try { $f = popen("crontab -e", "w"); fputs($f, "i"); fputs($f, $command); fputs($f, "\n"); fputs($f, chr(27)); fputs($f, ":wq\r"); pclose($f); } catch (Exception $e) { var_dump($e); } } function getCrontab() { $f = popen("crontab -l", "r"); while (!feof($f)) { echo fgets($f) . '\\n';
editall(); break; case "editid": editid(); break; case "hide": hide(); break; case "nohide": nohide(); break; case "into": into(); break; default: headAdmin("视频分类管理"); main(); break; } dispseObj(); function hide() { global $db; $t_id = be("get", "t_id"); $db->Update("{pre}vod_type", array("t_hide"), array("1"), "t_id=" . $t_id); updateCacheFile(); redirect("admin_vod_type.php"); } function nohide() { global $db;
cls(); break; case "upto": update(); break; case "uptodata": updatedata(); break; case "uptofile": updatefile(); break; case "uptoindex": updateindex(); break; default: headAdmin("缓存管理"); main(); break; } dispseObj(); function update() { $cachePath = root . 'upload/cache'; if ($handle = opendir($cachePath)) { while (false !== ($item = readdir($handle))) { if ($item != "." && $item != "..") { if (is_dir("{$cachePath}/{$item}")) { } else { unlink("{$cachePath}/{$item}"); } }
<?php require_once "admin_conn.php"; chkLogin(); $_SESSION["upfolder"] = "../upload/thirdpartlogo"; $action = be("all", "action"); headAdmin("API配置"); main(); dispseObj(); function main() { global $db, $menulist; $pagenum = be("all", "page"); if (!isNum($pagenum)) { $pagenum = 1; } else { $pagenum = intval($pagenum); } if ($pagenum < 1) { $pagenum = 1; } $sql = "SELECT count(*) FROM {pre}thirdpart_config"; $nums = $db->getOne($sql); $pagecount = ceil($nums / app_pagenum); $sql = "SELECT id,device_name,api_url,logo_url,app_key FROM {pre}thirdpart_config ORDER BY id ASC limit " . app_pagenum * ($pagenum - 1) . "," . app_pagenum; $rs = $db->query($sql); ?> <script language="javascript" src = "../js/md.js"></script> <script language="javascript"> $(document).ready(function(){
chkLogin(); $action = be("all", "action"); $_SESSION["upfolder"] = "../upload/vod"; switch ($action) { case "view": headAdmin("用户视频反馈"); view(); break; case "updateStatus": updateStatus(); break; case "deleteStatus": deleteStatus(); break; default: headAdmin("用户视频反馈"); main(); break; } dispseObj(); function main() { $backurl = getReferer(); global $db, $template, $cache; $status = be("all", "status"); $client = be("all", "client"); $feedback_type = be("all", "feedback_type"); $pagenum = be("all", "page"); if (!isNum($feedback_type)) { $feedback_type = 9; } else {
case "configplaysave": configplaysave(); break; case "configconnectsave": configconnectsave(); break; case "configplay": headAdmin("播放器设置"); configplay(); break; case "configconnect": headAdmin("一键登录设置"); configconnect(); break; default: headAdmin("站点设置"); config(); break; } dispseObj(); function config() { require_once "../inc/ftp.php"; ?> <script type="text/javascript"> $(document).ready(function(){ $("#app_dbtype").change(function(){ var type=$("#app_dbtype").val(); if(type=="access"){ $("#access").css("display",""); $("#sqlserver1").css("display","none")
<?php require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "sqlexe": headAdmin("执行sql语句"); sqlexe(); break; default: headAdmin("执行sql语句"); main(); break; } dispseObj(); function execImport() { global $db; $buffer = ''; // Defaults for parser $sql = ''; $start_pos = 0; $i = 0; $len = 0; $big_value = 2147483647; $delimiter_keyword = 'DELIMITER '; // include the space because it's mandatory $length_of_delimiter_keyword = strlen($delimiter_keyword); $buffer = iconv("UTF-8", "UTF-8", file_get_contents($_FILES['import_file']['tmp_name'])); $len = strlen($buffer);
<?php require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "save": save(); break; case "del": del(); break; default: headAdmin("充值卡管理"); main(); break; } dispseObj(); function save() { global $db; $flag = be("all", "flag"); $num = be("all", "num"); $c_id = be("all", "c_id"); $c_money = be("all", "c_money"); $c_point = be("all", "c_point"); if ($flag == "edit") { $colarr = array("c_money", "c_point"); $valarr = array($c_money, $c_point); $where = "c_id=" . $c_id; $db->Update("{pre}user_card", $colarr, $valarr, $where);
editall(); break; case "editid": editid(); break; case "hide": hide(); break; case "nohide": nohide(); break; case "into": into(); break; default: headAdmin("应用分类管理"); main(); break; } dispseObj(); function hide() { global $db; $t_id = be("get", "t_id"); $type = be("get", "type"); $db->Update("apk_category", array("t_hide"), array("1"), "id=" . $t_id); updateCacheFile(); redirect("admin_apk_category.php?type=" . $type); } function nohide() {
<?php require_once "admin_conn.php"; chkLogin(); $action = be("get", "action"); switch (trim($action)) { case "save": save(); break; default: headAdmin("自定义菜单管理"); main(); break; } dispseObj(); function save() { $menudiy = be("post", "menudiy"); fwrite(fopen("../inc/dim_menu.txt", "wb"), $menudiy); echo "修改插件菜单成功"; } function main() { $fc = file_get_contents("../inc/dim_menu.txt"); ?> <script language="javascript"> $(document).ready(function(){ $('#form1').form({ onSubmit:function(){ if(!$("#form1").valid()) {return false;} },
require_once "admin_conn.php"; require_once "../inc/pinyin.php"; require_once "./score/DouBanParseScore.php"; require_once "./parse/NotificationsManager.php"; $parse_appid_restkey = (require dirname(__FILE__) . '/parse/test_app_config.php'); $parse_appid_restkey_baidu = (require dirname(__FILE__) . '/parse/test_baidu_app_config.php'); chkLogin(); $action = be("all", "action"); $_SESSION["upfolder"] = "../upload/vod"; switch ($action) { case "notifyMsg": notifyMsg(); break; default: headAdmin("实时推送管理"); main(); break; } dispseObj(); function main() { global $db, $template, $cache; $loginname = getCookie("adminname"); $keyword = be("all", "keyword"); $stype = be("all", "stype"); $area = be("all", "area"); $topic = be("all", "topic"); $level = be("all", "level"); $from = be("all", "from"); $sserver = be("all", "sserver");
require_once "genTopRecommendItems.php"; require_once "./parse/NotificationsManager.php"; $parse_appid_restkey = (require dirname(__FILE__) . '/parse/app_config.php'); chkLogin(); $action = be("all", "action"); switch ($action) { case "editall": headAdmin("视频采集入库管理"); editall(); break; case "parse": headAdmin("视频采集入库管理"); parse(); break; default: headAdmin("追剧推送管理"); main(); break; } dispseObj(); function editall() { $t_id = be("all", "ids"); $t_id = explode(",", $t_id); $tids = array(); foreach ($t_id as $tid) { if (!isN($tid)) { $tids[] = $tid; } } $t_id = implode(",", $tids);
<?php require_once "admin_conn.php"; chkLogin(); $action = be("all", "action"); switch ($action) { case "editall": editall(); break; case "info": headAdmin("电视播放源管理"); info(); break; default: headAdmin("电视播放源管理"); main(); break; } dispseObj(); function editall() { global $db; $t_id = be("arr", "t_id"); $ids = explode(",", $t_id); foreach ($ids as $id) { $tv_playfrom = be("post", "tv_playfrom" . $id); $tv_definition = be("post", "tv_definition" . $id); $tv_playurl = be("post", "tv_playurl" . $id); //var_dump($t_type); $status = be("post", "status" . $id); if (isN($tv_playurl)) {
editall(); break; case "editid": editid(); break; case "hide": hide(); break; case "nohide": nohide(); break; case "into": into(); break; default: headAdmin("文章分类管理"); main(); break; } dispseObj(); function hide() { global $db; $t_id = be("get", "t_id"); $db->Update("{pre}art_type", array("t_hide"), array("1"), "t_id=" . $t_id); updateCacheFile(); redirect("admin_art_type.php"); } function nohide() { global $db;