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


PHP usersMenus::IsSquidReverse方法代码示例

本文整理汇总了PHP中usersMenus::IsSquidReverse方法的典型用法代码示例。如果您正苦于以下问题:PHP usersMenus::IsSquidReverse方法的具体用法?PHP usersMenus::IsSquidReverse怎么用?PHP usersMenus::IsSquidReverse使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在usersMenus的用法示例。


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

示例1: all_services_status_build

function all_services_status_build()
{
    $page = CurrentPageName();
    $sock = new sockets();
    $ini = new Bs_IniHandler();
    $tpl = new templates();
    $users = new usersMenus();
    $squid = new squidbee();
    $ini->loadString(base64_decode($sock->getFrameWork('cmd.php?squid-ini-status=yes')));
    if (!is_numeric($MonitConfig["watchdog"])) {
        $MonitConfig["watchdog"] = 1;
    }
    $DisableAnyCache = $sock->GET_INFO("DisableAnyCache");
    $SquidActHasReverse = $sock->GET_INFO("SquidActHasReverse");
    $AsSquidLoadBalancer = $sock->GET_INFO("AsSquidLoadBalancer");
    $EnableRemoteStatisticsAppliance = $sock->GET_INFO("EnableRemoteStatisticsAppliance");
    $EnableKerbAuth = $sock->GET_INFO("EnableKerbAuth");
    if (!is_numeric($DisableAnyCache)) {
        $DisableAnyCache = 0;
    }
    $SquidBoosterMem = $sock->GET_INFO("SquidBoosterMem");
    $SquidCacheLevel = $sock->GET_INFO("SquidCacheLevel");
    if (!is_numeric($SquidCacheLevel)) {
        $SquidCacheLevel = 4;
    }
    if (!is_numeric($EnableKerbAuth)) {
        $EnableKerbAuth = 0;
    }
    if (!is_numeric($SquidBoosterMem)) {
        $SquidBoosterMem = 0;
    }
    if (!is_numeric($DisableAnyCache)) {
        $DisableAnyCache = 0;
    }
    if (!is_numeric($SquidActHasReverse)) {
        $SquidActHasReverse = 0;
    }
    if (!is_numeric($AsSquidLoadBalancer)) {
        $AsSquidLoadBalancer = 0;
    }
    if (!is_numeric($EnableRemoteStatisticsAppliance)) {
        $EnableRemoteStatisticsAppliance = 0;
    }
    $UnlockWebStats = $sock->GET_INFO("UnlockWebStats");
    if (!is_numeric($UnlockWebStats)) {
        $UnlockWebStats = 0;
    }
    if ($UnlockWebStats == 1) {
        $EnableRemoteStatisticsAppliance = 0;
    }
    if ($SquidCacheLevel == 0) {
        $DisableAnyCache = 1;
    }
    $squid_status = DAEMON_STATUS_ROUND("SQUID", $ini, null, 1);
    $dansguardian_status = DAEMON_STATUS_ROUND("DANSGUARDIAN", $ini, null, 1);
    $kav = DAEMON_STATUS_ROUND("KAV4PROXY", $ini, null, 1);
    $cicap = DAEMON_STATUS_ROUND("C-ICAP", $ini, null, 1);
    $APP_PROXY_PAC = DAEMON_STATUS_ROUND("APP_PROXY_PAC", $ini, null, 1);
    $APP_SQUIDGUARD_HTTP = DAEMON_STATUS_ROUND("APP_SQUIDGUARD_HTTP", $ini, null, 1);
    $APP_UFDBGUARD = DAEMON_STATUS_ROUND("APP_UFDBGUARD", $ini, null, 1);
    $APP_FRESHCLAM = DAEMON_STATUS_ROUND("APP_FRESHCLAM", $ini, null, 1);
    $APP_ARTICADB = DAEMON_STATUS_ROUND("APP_ARTICADB", $ini, null, 1);
    $APP_SQUID_DB = DAEMON_STATUS_ROUND("APP_SQUID_DB", $ini, null, 1);
    $APP_HAARP = DAEMON_STATUS_ROUND("APP_HAARP", $ini, null, 1);
    if ($users->PROXYTINY_APPLIANCE) {
        $APP_ARTICADB = null;
    }
    if ($EnableRemoteStatisticsAppliance == 1) {
        $APP_ARTICADB = null;
    }
    $APP_FTP_PROXY = DAEMON_STATUS_ROUND("APP_FTP_PROXY", $ini, null, 1);
    $squid = new squidbee();
    if ($EnableKerbAuth == 1) {
        $APP_SAMBA_WINBIND = DAEMON_STATUS_ROUND("SAMBA_WINBIND", $ini, null, 1);
    }
    $tr[] = "<div id='squid-mem-status'></div><script>LoadAjaxTiny('squid-mem-status','{$page}?squid-mem-status=yes');</script>";
    $tr[] = "<div id='squid-stores-status'></div><script>LoadAjaxTiny('squid-stores-status','{$page}?squid-stores-status=yes');</script>";
    $md = md5(date('Ymhis'));
    if (!$users->WEBSTATS_APPLIANCE) {
        $swappiness = intval($sock->getFrameWork("cmd.php?sysctl-value=yes&key=" . base64_encode("vm.swappiness")));
        $sock = new sockets();
        $swappiness_saved = unserialize(base64_decode($sock->GET_INFO("kernel_values")));
        if (!is_numeric($swappiness_saved["swappiness"])) {
            if ($swappiness > 30) {
                $tr[] = DAEMON_STATUS_ROUND_TEXT("warning-panneau-42.png", "{high_swap_value}", "{high_swap_value_text}", "Loadjs('squid.perfs.php')");
            }
        }
        if ($AsSquidLoadBalancer == 1) {
            $SquidAsSeenDNS = 1;
        }
        if (!$users->IsSquidReverse()) {
            $SquidAsSeenDNS = $sock->GET_INFO("SquidAsSeenDNS");
            if (!is_numeric($SquidAsSeenDNS)) {
                $SquidAsSeenDNS = 0;
            }
            if (count($squid->dns_array) == 0) {
                if ($SquidAsSeenDNS == 0) {
                    $tr[] = DAEMON_STATUS_ROUND_TEXT("warning-panneau-42.png", "{add_dns_in_config}", "{add_dns_in_config_perf_explain}", "Loadjs('squid.popups.php?script=dns')");
                }
            }
//.........这里部分代码省略.........
开发者ID:brucewu16899,项目名称:1.6.x,代码行数:101,代码来源:miniadmin.proxy.monitor.php


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