当前位置: 首页>>代码示例>>PHP>>正文


PHP headAdmin函数代码示例

本文整理汇总了PHP中headAdmin函数的典型用法代码示例。如果您正苦于以下问题:PHP headAdmin函数的具体用法?PHP headAdmin怎么用?PHP headAdmin使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了headAdmin函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: chkLogin

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");
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_art.php

示例2: switch

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";
        }
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:index.php

示例3: chkLogin

<?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");
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_program_items.php

示例4: chkLogin

<?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);
    ?>
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_user.php

示例5: chkLogin

<?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;
        }
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_vod_topic_items.php

示例6: chkLogin

<?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='" . md5($oldP) . "' 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()
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_forgot_pwd.php

示例7: getPage

$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);
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_update.php

示例8: chkLogin

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);
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_program_play_import.php

示例9: chkLogin

<?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:{
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_timming.php

示例10: chkLogin

<?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)) {
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_art_topic.php

示例11: delall

        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)
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_db.php

示例12: chkLogin

<?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)) {
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_apk_company.php

示例13: chkLogin

<?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 {
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_gbook.php

示例14: chkLogin

<?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:{
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_user_group.php

示例15: save

        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");
开发者ID:andyongithub,项目名称:joyplus-cms,代码行数:31,代码来源:admin_ads.php


注:本文中的headAdmin函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。