當前位置: 首頁>>代碼示例>>PHP>>正文


PHP CMediusers::isInstalled方法代碼示例

本文整理匯總了PHP中CMediusers::isInstalled方法的典型用法代碼示例。如果您正苦於以下問題:PHP CMediusers::isInstalled方法的具體用法?PHP CMediusers::isInstalled怎麽用?PHP CMediusers::isInstalled使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在CMediusers的用法示例。


在下文中一共展示了CMediusers::isInstalled方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: updateSpecs

 /**
  * Update the object's specs
  *
  * @return void
  **/
 function updateSpecs()
 {
     $oldSpec = $this->_specs['_user_password'];
     $user = new CMediusers();
     $remote = 0;
     if ($user->isInstalled()) {
         if ($result = $user->load($this->user_id)) {
             $remote = $user->remote;
         }
     }
     // Determine if password length is sufficient
     $strongPassword = CAppUI::conf("admin CUser strong_password") == "1" && ($remote == 0 || CAppUI::conf("admin CUser apply_all_users"));
     // If the global strong password config is set to TRUE and the user can connect remotely
     $this->_specs['_user_password'] = $strongPassword ? $this->_specs['_user_password_strong'] : $this->_specs['_user_password_weak'];
     $this->_specs['_user_password']->fieldName = $oldSpec->fieldName;
     $this->_props['_user_password'] = $strongPassword ? $this->_props['_user_password_strong'] : $this->_props['_user_password_weak'];
 }
開發者ID:fbone,項目名稱:mediboard4,代碼行數:22,代碼來源:CUser.class.php

示例2: gmdate

// HTTP headers
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
// Date in the past
header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
// always modified
header("Cache-Control: no-cache, no-store, must-revalidate");
// HTTP/1.1
header("Pragma: no-cache");
// HTTP/1.0
header("X-UA-Compatible: IE=edge");
// Force IE document mode
// Show errors to admin
ini_set("display_errors", CAppUI::pref("INFOSYSTEM"));
CMbPerformance::mark("headers");
$user = new CMediusers();
if ($user->isInstalled()) {
    $user->load(CAppUI::$instance->user_id);
    $user->getBasicInfo();
    CAppUI::$user = $user;
    CAppUI::$instance->_ref_user =& CAppUI::$user;
    CApp::$is_robot = CAppUI::$user->isRobot();
    // Offline mode for non-admins
    if ($dPconfig["offline_non_admin"] && CAppUI::$user->_id != 0 && !CAppUI::$user->isAdmin()) {
        CApp::goOffline("maintenance");
    }
}
CMbPerformance::mark("user");
// Load DB-stored configuration schema
$configurations = glob(__DIR__ . "/modules/*/configuration.php");
foreach ($configurations as $_configuration) {
    include $_configuration;
開發者ID:OpenXtrem,項目名稱:mediboard-test,代碼行數:31,代碼來源:index.php


注:本文中的CMediusers::isInstalled方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。