• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

PHP parse_config函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

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



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

示例1: show_nav

function show_nav()
{
    $config = get_config();
    $master_url = parse_config($config, "<master_url>");
    $no_computing = parse_config($config, "<no_computing>");
    $no_web_account_creation = parse_bool($config, "no_web_account_creation");
    echo "<div class=\"mainnav\">\n\n        <h2 class=headline>Returning participants</h2>\n        <ul>\n    ";
    if ($no_computing) {
        echo "\n            <li><a href=\"bossa_apps.php\">Do work</a>\n            <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n            <li><a href=\"team.php\">Teams</a> - create or join a team\n        ";
    } else {
        echo "\n            <li><h3 class=headline > <a href=\"home.php\">Your account</a> - Create/List Tasks , stats, preferences </h3>\n            <li><a href=server_status.php>Server status</a>\n            <li><a href=\"team.php\">Teams</a> - create or join a team\n            <li><a href=\"cert1.php\">Certificate</a>\n            <li><a href=\"apps.php\">" . tra("Applications") . "</a>\n        ";
    }
    echo "\n        </ul>";
    echo "<div class=\"mainnav\">\n        <h2 class=headline>About " . PROJECT . "</h2>\n    ";
    if ($no_computing) {
        echo "\n            " . SHORT_NAME . " is a research project that uses volunteers\n            to do research in Electromechanical Activity in the Human Heart.\n        ";
    } else {
        echo "\n            " . SHORT_NAME . " is a research project that uses Internet-connected\n            computers to do research in Electromechanical Activity in the Human Heart.\n            You can participate by downloading and running a free program\n            on your computer.\n        ";
    }
    echo "\n        <p>\n        " . SHORT_NAME . " is based at \n        USJ, Universidad San Jorge <a href=\"http://www.usj.es\">www.usj.es</a>\n        <ul>\n        <li> Code (and request modificacions) is available for web interface at <a href=\"https://github.com/rampxxxx/em\">https://github.com/rampxxxx/em</a>\n        <li> Code  (and request modificacions) is available for boinc daemons at <a href=\"https://github.com/rampxxxx/boinc\">https://github.com/rampxxxx/boinc</a>\n        <li> Code  (and request modificacions) is available for EM models at <a href=\"https://github.com/rampxxxx/TestEM\">https://github.com/rampxxxx/TestEM</a>\n        </ul>\n        <h2 class=headline>Join " . PROJECT . "</h2>\n        <ul>\n    ";
    if ($no_computing) {
        echo "\n            <li> <a href=\"create_account_form.php\">Create an account</a>\n        ";
    } else {
        echo "\n            <li><a href=\"info.php\">" . tra("Read our rules and policies") . "</a>\n            <li> This project uses BOINC.\n                If you're already running BOINC, select Add Project.\n                If not, <a target=\"_new\" href=\"http://boinc.berkeley.edu/download.php\">download BOINC</a>.\n            <li> When prompted, enter <br><b>" . $master_url . "</b>\n        ";
        if (!$no_web_account_creation) {
            echo "\n                <li> If you're running a command-line version of BOINC,\n                    <a href=\"create_account_form.php\">create an account</a> first.\n            ";
        }
        echo "\n            <li> If you have any problems,\n                <a target=\"_new\" href=\"http://boinc.berkeley.edu/wiki/BOINC_Help\">get help here</a>.\n        ";
    }
    echo "\n        </ul>";
    echo "\n        <h2 class=headline>" . tra("Community") . "</h2>\n        <ul>\n        <li><a href=\"profile_menu.php\">" . tra("Profiles") . "</a>\n        <li><a href=\"user_search.php\">User search</a>\n        <li><a href=\"forum_index.php\">" . tra("Message boards") . "</a>\n        <li><a href=\"forum_help_desk.php\">" . tra("Questions and Answers") . "</a>\n        <li><a href=\"stats.php\">Statistics</a>\n        <li><a href=language_select.php>Languages</a>\n        </ul>\n        </div>\n    ";
}
开发者ID:rampxxxx,项目名称:em,代码行数:32,代码来源:index.php


示例2: show_nav

function show_nav()
{
    $config = get_config();
    $master_url = parse_config($config, "<master_url>");
    $no_computing = parse_config($config, "<no_computing>");
    $no_web_account_creation = parse_bool($config, "no_web_account_creation");
    echo "<div class=\"mainnav\">\n        <h2 class=headline>About " . PROJECT . "</h2>\n    ";
    if ($no_computing) {
        echo "\n            XXX is a research project that uses volunteers\n            to do research in XXX.\n        ";
    } else {
        echo "\n            XXX is a research project that uses Internet-connected\n            computers to do research in XXX.\n            You can participate by downloading and running a free program\n            on your computer.\n        ";
    }
    echo "\n        <p>\n        XXX is based at \n        [describe your institution, with link to web page]\n        <ul>\n        <li> [Link to page describing your research in detail]\n        <li> [Link to page listing project personnel, and an email address]\n        </ul>\n        <h2 class=headline>Join " . PROJECT . "</h2>\n        <ul>\n    ";
    if ($no_computing) {
        echo "\n            <li> <a href=\"create_account_form.php\">Create an account</a>\n        ";
    } else {
        echo "\n            <li><a href=\"info.php\">" . tra("Read our rules and policies") . "</a>\n            <li> This project uses BOINC.\n                If you're already running BOINC, select Add Project.\n                If not, <a target=\"_new\" href=\"http://boinc.berkeley.edu/download.php\">download BOINC</a>.\n            <li> When prompted, enter <br><b>" . $master_url . "</b>\n        ";
        if (!$no_web_account_creation) {
            echo "\n                <li> If you're running a command-line version of BOINC,\n                    <a href=\"create_account_form.php\">create an account</a> first.\n            ";
        }
        echo "\n            <li> If you have any problems,\n                <a target=\"_new\" href=\"http://boinc.berkeley.edu/wiki/BOINC_Help\">get help here</a>.\n        ";
    }
    echo "\n        </ul>\n\n        <h2 class=headline>Returning participants</h2>\n        <ul>\n    ";
    if ($no_computing) {
        echo "\n            <li><a href=\"bossa_apps.php\">Do work</a>\n            <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n            <li><a href=\"team.php\">Teams</a> - create or join a team\n        ";
    } else {
        echo "\n            <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n            <li><a href=server_status.php>Server status</a>\n            <li><a href=\"team.php\">Teams</a> - create or join a team\n            <li><a href=\"cert1.php\">Certificate</a>\n            <li><a href=\"apps.php\">" . tra("Applications") . "</a>\n        ";
    }
    echo "\n        </ul>\n        <h2 class=headline>" . tra("Community") . "</h2>\n        <ul>\n        <li><a href=\"profile_menu.php\">" . tra("Profiles") . "</a>\n        <li><a href=\"user_search.php\">User search</a>\n        <li><a href=\"forum_index.php\">" . tra("Message boards") . "</a>\n        <li><a href=\"forum_help_desk.php\">" . tra("Questions and Answers") . "</a>\n        <li><a href=\"stats.php\">Statistics</a>\n        <li><a href=language_select.php>Languages</a>\n        </ul>\n        </div>\n    ";
}
开发者ID:nicolas17,项目名称:boincgit-test,代码行数:30,代码来源:sample_index.php


示例3: add_base_packages_menu_items

function add_base_packages_menu_items()
{
    global $g, $config;
    $base_packages = split($g['base_packages'], ",");
    $modified_config = false;
    foreach ($base_packages as $bp) {
        $basepkg_path = "/usr/local/pkg/";
        if (file_exists($basepkg_path . $configfile)) {
            $pkg_config = parse_xml_config_pkg($basepkg_path . $bp, "packagegui");
            if ($pkg_config['menu'] != "") {
                if (is_array($pkg_config['menu'])) {
                    foreach ($pkg_config['menu'] as $menu) {
                        if (is_array($config['installedpackages']['menu'])) {
                            foreach ($config['installedpackages']['menu'] as $amenu) {
                                if ($amenu['name'] == $menu['name']) {
                                    continue;
                                }
                            }
                        }
                        $config['installedpackages']['menu'][] = $menu;
                        $modified_config = true;
                    }
                }
                $static_output .= "done.\n";
                update_output_window($static_output);
            }
        }
    }
    if ($modified_config) {
        write_confg("Restored base_package menus after configuration restore.");
        $config = parse_config(true);
    }
}
开发者ID:rootsghost,项目名称:5651-pfsense,代码行数:33,代码来源:diag_backup.php


示例4: setInfo

 public function setInfo($type, $detail, $originalxml, $denytag, $otherparam)
 {
     $detail = unserialize($detail);
     switch (strtolower($detail['type'])) {
         case 'cloud':
             $apiinfo = M('Webuntil')->where(array('id' => $detail['neiron']))->field('id,webuntil_param,webuntil_type,webuntil_backtype,webuntil_sigtype,webuntil_cache,webuntil_tag,webuntil_url,webuntil_token')->find();
             $oldparam = parse_config($apiinfo['webuntil_param']);
             $newparam = $detail['replace'];
             //为了更好的合并参数提交
             $apiinfo['webuntil_param'] = array_merge($oldparam, $newparam);
             //判断是否存在缓存
             $oldinfo = excute_cache($apiinfo['id'], '', $apiinfo['webuntil_cache'], $is_echo = false);
             $newcontent = empty($oldinfo) ? self::setCloud($apiinfo) : $oldinfo;
             return $newcontent;
             break;
         case 'local':
             $apiinfo = M('Addons')->where(array('id' => $detail['neiron'], 'status' => 1, 'weixin' => 1))->field('name,title,config')->find();
             if (empty($apiinfo)) {
                 wx_error('Sorry!该插件暂未启用或者未安装');
             } else {
                 defined('AMANGO_ADDON_NAME') or define('AMANGO_ADDON_NAME', ucfirst($apiinfo['name']));
             }
             $publicpath = str_replace('./', 'http://' . $_SERVER['HTTP_HOST'] . '/', ONETHINK_ADDON_PATH . AMANGO_ADDON_NAME . '/Public/');
             defined('ADDON_PUBLIC') or define('ADDON_PUBLIC', $publicpath);
             defined('ADDON_ROOT') or define('ADDON_ROOT', ONETHINK_ADDON_PATH . AMANGO_ADDON_NAME . '/');
             Amango_Addons($apiinfo['name'], '', '', $detail['replace'], true);
             break;
         case 'behavior':
             wx_error('Sorry!暂不支持行为动作,下个版本即将推出');
             break;
         default:
             wx_error('未定义的第三方接口');
             break;
     }
 }
开发者ID:fedkey,项目名称:amango,代码行数:35,代码来源:ApiFactory.class.php


示例5: xml_parse_tags

/**
 * 循环标签匹配
 * $matches  为匹配到的内容[数组]
 * 统一隐式传参 session('from')  session('to')
 * @return string 
 */
function xml_parse_tags($matches)
{
    $taglist = array();
    $taglist = session('AMANGO_PARSETAGS');
    preg_match('/(?<=<amango:)[^>]+(?=>)/', $matches[1], $tag_name);
    $tagname = str_replace('tag', '', $tag_name[0]);
    $tagitem = $taglist[$tagname];
    if (empty($tagitem)) {
        return "";
    } else {
        //wx_error(json_encode($tagitem));
        foreach ($tagitem as $key => $value) {
            switch (strtolower($value['type'])) {
                case 'func':
                    $funcname = $value['action'];
                    $str[$key] = $funcname($value['param']);
                    break;
                case 'action':
                    $actionname = $value['action'];
                    $param = array();
                    $param = parse_config($value['param']);
                    $str[$key] = R($actionname, $param);
                    break;
                case 'static':
                    $str[$key] = $value['param'];
                    break;
                default:
                    wx_error('标签解析不存在');
                    break;
            }
        }
        $newstr = implode("\n", $str);
        return $newstr . "\n";
    }
}
开发者ID:wmk223,项目名称:amango_V3,代码行数:41,代码来源:tool.php


示例6: get_lists

function get_lists()
{
    $config = get_config();
    $db_name = parse_config($config, "<db_name>");
    $db_host = parse_config($config, "<db_host>");
    system("mysql {$db_name} -h {$db_host} -e \"select workunitid, id from result \" | tail +2 | sort -n > dbc_res.dat");
    system("mysql {$db_name} -h {$db_host} -e \"select id from workunit\" | tail +2 | sort -n > dbc_wu.dat");
}
开发者ID:entibasse,项目名称:superhost,代码行数:8,代码来源:db_cleanse.php


示例7: check_score

 public function check_score()
 {
     $allscore = I('post.score');
     $param = parse_config(I('post.score_param'));
     foreach ($param as $key => $value) {
         if (!is_numeric($key) || $key > $allscore) {
             return false;
         }
     }
     return true;
 }
开发者ID:fedkey,项目名称:amango,代码行数:11,代码来源:AddonsexamModel.class.php


示例8: boinc_recaptcha_get_head_extra

function boinc_recaptcha_get_head_extra()
{
    // are we using recaptcha?
    $publickey = parse_config(get_config(), "<recaptcha_public_key>");
    if ($publickey) {
        // the meta tag must be included
        // for Recaptcha to work with some IE browsers
        return '<meta http-equiv="X-UA-Compatible" content="IE=EmulateIE8" >
        <script src="https://www.google.com/recaptcha/api.js" async defer></script>';
    } else {
        return null;
    }
}
开发者ID:aggroskater,项目名称:boinc,代码行数:13,代码来源:recaptchalib.php


示例9: get

 /**
  * Function get
  * @param string $_scope
  * @param string $_interface
  * @return Ambigous <Array api_struct, boolean false>
  */
 public static function get($_service = NULL, $_method = NULL, $_http_method = 'GET')
 {
     $_result = FALSE;
     if ($_service != NULL && $_method != NULL) {
         $_result = parse_config(API_CONF_FILE_PATH);
     }
     if ($_result != NULL && isset($_result[$_service . '/' . $_method . '?' . $_http_method])) {
         $_result = $_result[$_service . '/' . $_method . '?' . $_http_method];
     } else {
         $_result = FALSE;
     }
     return $_result;
 }
开发者ID:randy-ran,项目名称:open-api-for-vopi,代码行数:19,代码来源:Api.php


示例10: config_load

 function &getConfig($reload = false)
 {
     if (!isset($this->config) || $reload) {
         if (isset($_SESSION['load_count'])) {
             $_SESSION['load_count'] += 1;
         } else {
             $_SESSION['load_count'] = 1;
         }
         $configinstance = config_load();
         $this->config =& parse_config($configinstance);
     }
     return $this->config;
 }
开发者ID:bwssytems,项目名称:domuslink,代码行数:13,代码来源:global.class.php


示例11: set_jstpl

function set_jstpl($link_url, $info, $list, $common, $id)
{
    //判断是否存在缓存  5小时
    $cachetpl = S('Addonsexamcache' . $id);
    if (!empty($cachetpl)) {
        return $cachetpl;
    }
    //不存在  重新定义
    //分享图片
    $img_url = get_cover_pic($info['logo']);
    //分数段
    $scoreparam = '';
    $score_param = array();
    $score_param = parse_config($info['score_param']);
    foreach ($score_param as $key => $value) {
        $scoreparam .= '{score: ' . $key . ',comment: "' . $value . '"},';
    }
    //题目列表
    $queData = set_queData($list);
    $tpl = <<<str
(function() {
  window.amangoshare = {
    "img_url": "{$img_url}",
    "img_width": "120",
    "img_height": "120",
    "link": "{$link_url}",
    "desc": "我正在参加【{$info['title']}】!你也来试试!",
    "title": "{$info['title']}"
  };
  window.buttonurl   = [
      '{$common[0]}',
      '{$common[1]}',
      '{$common[2]}',
      '{$common[3]}',
  ];
  window.nowdatajson = {
    queData: [
      {$queData}
    ],
    fullScore: {$info['score']},
    scoreArray: [
      {$scoreparam}
    ]
  };

}).call(this);
str;
    S('Addonsexamcache' . $id, $tpl, 60 * 60);
    return $tpl;
}
开发者ID:fedkey,项目名称:amango,代码行数:50,代码来源:functions.php


示例12: show_nav

function show_nav()
{
    $config = get_config();
    $master_url = parse_config($config, "<master_url>");
    $no_computing = parse_config($config, "<no_computing>");
    $no_web_account_creation = parse_bool($config, "no_web_account_creation");
    $disable_acct = parse_bool($config, "disable_account_creation");
    echo "<div class=\"mainnav\">\n        <h2 class=headline>About " . PROJECT . "</h2>\n    ";
    if ($no_computing) {
        echo "\n            XXX is a research project that uses volunteers\n            to do research in XXX.\n        ";
    } else {
        echo "\n            XXX is a research project that uses Internet-connected\n            computers to do research in XXX.\n            You can participate by downloading and running a free program\n            on your computer.\n        ";
    }
    echo "\n        <p>\n        XXX is based at \n        [describe your institution, with link to web page]\n        <ul>\n        <li> [Link to page describing your research in detail]\n        <li> [Link to page listing project personnel, and an email address]\n        </ul>\n        <h2 class=headline>Participate</h2>\n        <ul>\n    ";
    if ($no_computing) {
        if (!$no_web_account_creation && !$disable_acct) {
            echo "\n                <li> <a href=\"create_account_form.php\">Create an account</a>\n            ";
        } else {
            echo "<li> This project is not currently accepting new accounts.";
        }
    } else {
        echo "\n            <li><a href=\"info.php\">" . tra("Read our rules and policies") . "</a>\n        ";
        if (0) {
            echo "<li>";
            show_button("register.php", "Join", null, "btn btn-green");
        } else {
            echo "<li> <a href=http://boinc.berkeley.edu/download.php>Download</a> and run BOINC.\n                <li> Choose Add Project\n            ";
        }
        echo "\n            <li> If you have any problems,\n                <a target=\"_new\" href=\"http://boinc.berkeley.edu/wiki/BOINC_Help\">get help here</a>.\n        ";
    }
    echo "\n        </ul>\n\n        <h2 class=headline>Returning participants</h2>\n        <ul>\n        <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n    ";
    if (!$no_computing) {
        echo "\n            <li><a href=server_status.php>Server status</a>\n            <li><a href=\"cert1.php\">Certificate</a>\n            <li><a href=\"apps.php\">" . tra("Applications") . "</a>\n        ";
    }
    if (!DISABLE_TEAMS) {
        echo "\n            <li><a href=\"team.php\">Teams</a> - create or join a team\n        ";
    }
    echo "\n        </ul>\n        <h2 class=headline>" . tra("Community") . "</h2>\n        <ul>\n    ";
    if (!DISABLE_PROFILES) {
        echo "\n            <li><a href=\"profile_menu.php\">" . tra("Profiles") . "</a>\n        ";
    }
    echo "\n        <li><a href=\"user_search.php\">User search</a>\n        <li><a href=ffmail_form.php>Share</a>\n    ";
    if (!DISABLE_FORUMS) {
        echo "\n            <li><a href=\"forum_index.php\">" . tra("Message boards") . "</a>\n            <li><a href=\"forum_help_desk.php\">" . tra("Questions and Answers") . "</a>\n        ";
    }
    echo "\n        <li><a href=\"stats.php\">Statistics</a>\n        <li><a href=language_select.php>Languages</a>\n        </ul>\n        </div>\n    ";
}
开发者ID:WilliamStilte,项目名称:boinc,代码行数:47,代码来源:sample_index.php


示例13: show_auth_form

function show_auth_form()
{
    $master_url = parse_config(get_config(), "<master_url>");
    $x = strstr($master_url, "//");
    $x = substr($x, 2);
    $x = rtrim($x, "/");
    $x = str_replace("/", "_", $x);
    $account_file = "account_{$x}.xml";
    echo "<p><h3>" . tra("2) If you forgot your account's email address, or you can't receive email there:") . "</h3>" . tra("If you have run BOINC under this account, you can still access it. Here's how:") . "\n\n    <ul>\n    <li> " . tra("Go to the BOINC data directory on your computer (its location is written to the Event Log at startup).") . "\n    <li> " . tra("Find your account file for this project; it will be named <b>%1</b>.", $account_file) . "\n    <li> " . tra("Open the file in a text editor like Notepad. You'll see something like") . "\n    <pre>\n    &lt;account>\n        &lt;master_url>{$master_url}&lt;/master_url>\n        &lt;authenticator>8b8496fdd26df7dc0423ecd43c09a56b&lt;/authenticator>\n        &lt;project_name>" . PROJECT . "&lt;/project_name>\n        ...\n    &lt;/account>\n    </pre>\n\n    <li> " . tra("Select and Copy the string between %1 and %2 (%3 in the above example).", "&lt;authenticator>", "&lt;/authenticator>", "<b>8b8496fdd26df7dc0423ecd43c09a56b</b>") . "\n\n    <li> " . tra("Paste the string into the field below, and click OK.") . "\n    <li> " . tra("You will now be logged in to your account; update the email and password of your account.") . "\n    </ul>\n    ";
    start_table();
    echo "<form action=login_action.php method=post>\n";
    row2(tra("Log in with authenticator"), "<input type=\"text\" name=authenticator size=40>");
    row2(tra("Stay logged in on this computer"), "<input type=checkbox name=send_cookie checked>");
    row2("", "<input class=\"btn btn-default\" type=submit value=\"" . tra("OK") . "\">");
    echo "</form>";
    end_table();
}
开发者ID:privat1,项目名称:boinc,代码行数:17,代码来源:get_passwd.php


示例14: show_nav

function show_nav()
{
    $config = get_config();
    $master_url = parse_config($config, "<master_url>");
    $no_computing = parse_config($config, "<no_computing>");
    $no_web_account_creation = parse_bool($config, "no_web_account_creation");
    $user = get_logged_in_user(false);
    echo "<div class=\"mainnav\">\n        <h2 class=headline>About " . PROJECT . "</h2>\n    ";
    echo "\n        The Quake Catcher Network (QCN) is a research project that uses Internet-connected\n        computers to do research, education, and outreach in seismology.\n        You can participate by downloading and running a free program\n        on your computer.  Currently only certain Mac (OS X) PPC and Intel laptops are supported --\n        recent ones which have a built-in accelerometer.  You can also buy an external USB accelerometer.\n        <p>\n        QCN is based at the Stanford University School of Earth Sciences.\n        <ul>\n        <li> <A HREF=\"" . BASEURL . "/index.php\">Quake Catcher Network Home Page</A>\n        <li> <A HREF=\"" . BASEURL . "/about-qcn/contact-us\">Project Personnel</A>\n        </ul>\n       ";
    if ($no_computing) {
        echo "\n            <li> <a href=\"create_account_form.php\">Create an account</a>\n        ";
    } else {
        echo "\n            <li><a href=\"info.php\">" . tra("Read our rules and policies") . "</a>\n            <li> This project uses BOINC.\n                If you're already running BOINC, select Add Project.\n                If not, <a target=\"_new\" href=\"http://boinc.berkeley.edu/download.php\">download BOINC</a>.\n            <li> When prompted, enter <br><b>" . $master_url . "</b>\n        ";
        if (!$no_web_account_creation) {
            echo "\n                <li> If you're running a command-line version of BOINC,\n                    <a href=\"create_account_form.php\">create an account</a> first.\n            ";
        }
        echo "\n            <li> If you have any problems,\n                <a target=\"_new\" href=\"http://boinc.berkeley.edu/wiki/BOINC_Help\">get help here</a>.\n        ";
    }
    echo "\n        </ul><BR><p>\n\n        <h2 class=headline>Returning participants</h2>\n        <ul>\n    ";
    if ($no_computing) {
        echo "\n            <li><a href=\"bossa_apps.php\">Do work</a>\n            <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n            <li><a href=\"team.php\">Teams</a> - create or join a team\n        ";
    } else {
        echo "\n            <li><a href=\"home.php\">Your account</a> - view stats, modify preferences\n            <li><a href=server_status.php>Server status</a>\n            <li><a href=\"team.php\">Teams</a> - create or join a team\n            <li><a href=\"cert1.php\">Certificate</a>\n            <li><a href=\"apps.php\">" . tra("Applications") . "</a>\n        ";
    }
    echo "\n        </ul>\n        <h2 class=headline>" . tra("Community") . "</h2>\n        <ul>\n        <li><a href=\"user_search.php\">User search</a>\n        <li><a href=\"forum_index.php\">" . tra("Message boards") . "</a>\n        <li><a href=\"stats.php\">Statistics</a>\n        <li><a href=language_select.php>Languages</a>\n        </ul>\n    ";
    // CMC changed to forum prefs 4th bit
    if (qcn_admin_user_auth($user)) {
        // defined in project/project.inc
        echo "\n        <h2>" . tra("Extra Links") . "</h2>\n        <ul>\n        <li><a href=\"trdl.php\">" . tra("Trigger Search/Upload/Download Page") . "</a>\n        <li><a href=\"ramp.php\">" . tra("View RAMP Signups") . "</a>\n        <li><a href=\"" . BASEURL . "/sensor/todo\">" . tra("To-Do List") . "</a></ul>";
        //if ($user->id == 15) {
        // check for db replication timestamp
        #$kewfile = BASEPATH . "/boinc/sensor/html/user/max.txt";
        #if (file_exists($kewfile) && ($handle = fopen($kewfile, 'r'))) {
        #      $output = fgets($handle); // skip first line
        #      $output = fgets($handle);              fclose($handle);
        #      echo "        <li>Kew Sync Diff (seconds): " . $output . "<BR>(should be a small number else server is down) <BR>";
        #   }        else {
        #         echo "        <li>No Replication Sync File on Kew - Better Check!";
        # }
    }
    qcn_show_map();
    echo "     </div>";
}
开发者ID:happyj,项目名称:qcn,代码行数:43,代码来源:index.php


示例15: create_response

 public function create_response($resdata)
 {
     if (!is_numeric($resdata['apiid']) || empty($resdata['response_name'])) {
         return false;
     }
     $data = array();
     $param = parse_config($resdata['param']);
     //回复类型判断
     $data['response_reply'] = 'Api';
     //回复体标识
     $data['response_name'] = empty($resdata['response_name']) ? '本地接口,ID' . $resdata['apiid'] : $resdata['response_name'];
     //结构组合体
     $neiron = array('type' => 'local', 'num' => 1, 'neiron' => $resdata['apiid'], 'replace' => $param);
     $data['response_compos'] = serialize($neiron);
     //生成XML
     $data['response_xml'] = '';
     //数据静态化
     $data['response_static'] = 0;
     $data['status'] = 1;
     return $data;
 }
开发者ID:fedkey,项目名称:amango,代码行数:21,代码来源:WeixinkeywordModel.class.php


示例16: show_download_page

function show_download_page()
{
    page_head("Download required software");
    $config = get_config();
    $need_vbox = parse_bool($config, "need_vbox");
    $mcv = parse_config($config, "<min_core_client_version>");
    $dlv = "BOINC";
    $dl = "BOINC";
    if ($mcv) {
        $dlv .= " version " . version_string_maj_min_rel($mcv) . " or later";
    }
    $verb = "this is";
    if ($need_vbox) {
        $dl .= " and VirtualBox";
        $dlv .= " and VirtualBox";
        $verb = "these are";
    }
    echo "To participate in " . PROJECT . ", {$dlv} must be installed.\n        <p>\n        If {$verb} already installed, <a href=download.php?action=installed>click here</a>.  Otherwise\n        <p>\n    ";
    show_button("download.php?action=download", "Download {$dl}");
    echo "<p>\n        When the download is finished,\n        open the downloaded file to install BOINC.\n    ";
    page_tail();
}
开发者ID:CalvinZhu,项目名称:boinc,代码行数:22,代码来源:download.php


示例17: get_config

// BOINC is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
// See the GNU Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public License
// along with BOINC. If not, see <http://www.gnu.org/licenses/>.
//
// This file was modified by contributors of "BOINC Web Tweak" project.
require_once "../inc/db_ops.inc";
require_once "../inc/util_ops.inc";
require_once "../inc/uotd.inc";
require_once "../project/project.inc";
$config = get_config();
$cgi_url = parse_config($config, "<cgi_url>");
$stripchart_cgi_url = parse_config($config, "<stripchart_cgi_url>");
db_init();
$title = "Project Management";
admin_page_head($title);
// Notification area
echo "<ul>\n";
echo "<li>";
if (file_exists("../../local.revision")) {
    $local_rev = file_get_contents("../../local.revision");
}
if ($local_rev) {
    echo "Currently used SVN revision: " . $local_rev . "; ";
}
if (file_exists("../cache/remote.revision") && time() < filemtime("../cache/remote.revision") + 24 * 60 * 60) {
    $remote_rev = file_get_contents("../cache/remote.revision");
} else {
开发者ID:Turante,项目名称:boincweb,代码行数:31,代码来源:index.php


示例18: parse_element

         $jobstderr = parse_element($resultunit->stderr_out, "<stderr_txt>");
         if ($jobstderr) {
             row1("Error output of this job");
             row2("", $jobstderr);
         }
     }
 } else {
     $resultunit = mysql_fetch_object(mysql_query("SELECT * FROM result WHERE id=" . $workunit->canonical_resultid));
     $xmldoc = $resultunit->xml_doc_out;
     $nroffiles = 0;
     $cursor = 0;
     while ($tempfileinfo = parse_next_element($xmldoc, "<file_info>", &$cursor)) {
         $outputfiles[$nroffiles++] = parse_element($tempfileinfo, "<name>");
     }
     if ($nroffiles >= 1) {
         $fanoutnr = parse_config($config, "<uldl_dir_fanout>");
         row1("Output of this job");
         row2("Number of output files of job: ", $nroffiles);
         for ($index = 0; $index < $nroffiles; ++$index) {
             $filename = $outputfiles[$index];
             $url = "upload/" . fan_out_dir($filename, $fanoutnr) . "/" . $filename;
             $outputfilelink = '<a href="' . $url . '">' . $filename . '</a>';
             row2("Output file " . ($index + 1) . ": ", $outputfilelink);
         }
     }
     $jobstderr = parse_element($resultunit->stderr_out, "<stderr_txt>");
     if ($jobstderr) {
         row1("Error output of this job");
         row2("", $jobstderr);
     }
 }
开发者ID:maexlich,项目名称:boinc-igemathome,代码行数:31,代码来源:ops_queue_show_job.php


示例19: edit_posts

 /**
  * 编辑配置
  * @author yangweijie <[email protected]>
  */
 public function edit_posts($id = 0)
 {
     if (IS_POST) {
         $res['status'] = 0;
         //关键词头部信息初始化
         if (!empty($_POST['keyword_post']) && !empty($_POST['id'])) {
             //请求类型判断
             $date['keyword_post'] = $_POST['keyword_post'];
             //下文关键词是否开启
             $date['keyword_down'] = !empty($_POST['keyword_down']) ? $_POST['keyword_down'] : '';
             //上文继承关键词
             $date['keyword_top'] = is_numeric($_POST['keyword_top']) ? $_POST['keyword_top'] : 0;
             //关键词所属分组
             $date['keyword_group'] = empty($_POST['keyword_group']) ? 1 : $_POST['keyword_group'];
             //关键词缓存
             $date['keyword_cache'] = is_numeric($_POST['keyword_cache']) ? $_POST['keyword_cache'] : 0;
             //关键词有效期判断
             $date['keyword_start'] = strtotime($_POST['keyword_start']);
             $date['keyword_end'] = strtotime($_POST['keyword_end']);
             if (!empty($date['keyword_end']) && !empty($date['keyword_start'])) {
                 if ($date['keyword_end'] < $date['keyword_start']) {
                     $date['keyword_end'] = $date['keyword_start'] + 31536000;
                 }
             }
             //关键词后置行为初始化
             //标签隐藏 显示 关闭
             $date['denytag_keyword'] = serialize(parse_config($_POST['denytag_keyword'], $type = 3));
             //后续行为初始化
             $date['after_keyword'] = serialize(parse_config($_POST['after_keyword'], $type = 3));
             //菜单模式初始化
             $date['click_model'] = is_numeric($_POST['click_model']) ? $_POST['click_model'] : '';
             //模式锁定初始化
             if (empty($_POST['lock_model1'])) {
                 //直接  第一个 选择模块
                 if (is_numeric($_POST['lock_model'])) {
                     $modelinfo = M('Addons')->where(array('status' => 1, 'weixin' => 1, 'id' => $_POST['lock_model']))->field('id,name')->find();
                     $date['lock_model'] = ucfirst($modelinfo['name']) . '/index';
                 } else {
                     $date['lock_model'] = '';
                 }
             } else {
                 $date['lock_model'] = empty($_POST['lock_model']) ? '' : $_POST['lock_model1'];
             }
             $date['status'] = 1;
             $date['keyword_reply'] = $_POST['keyword_reply'];
             //关键词正则替代
             //正则标识
             if (empty($_POST['keyword_reply'])) {
                 $this->error('匹配规则不能为空');
             }
             $rule = M('Rules')->where(array( 

鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
PHP parse_config_attr函数代码示例发布时间:2022-05-15
下一篇:
PHP parse_color_declaration函数代码示例发布时间:2022-05-15
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap