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


PHP icms_core_Debug::vardump方法代码示例

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


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

示例1: icms_debug_vardump

/**
 * Output a dump of a variable
 *
 * @param string $var variable which will be dumped
 * @deprecated	Use icms_core_Debug::vardump() instead
 */
function icms_debug_vardump($var)
{
    icms_core_Debug::setDeprecated('icms_core_Debug::vardump');
    return icms_core_Debug::vardump($var);
}
开发者ID:LeeGlendenning,项目名称:formulize,代码行数:11,代码来源:debug_functions.php

示例2: authenticate

 /**
  * Authenticate using the OpenID protocol
  *
  * @param bool $debug Turn debug on or not
  * @return bool successful?
  */
 public function authenticate($debug = FALSE)
 {
     // check to see if we already have an OpenID response in SESSION
     if (isset($_SESSION['openid_response'])) {
         if ($debug) {
             icms_core_Debug::message(_CORE_OID_INSESSIONS);
         }
         $this->response = unserialize($_SESSION['openid_response']);
     } else {
         if ($debug) {
             icms_core_Debug::message(_CORE_OID_FETCHING);
         }
         // Complete the authentication process using the server's response.
         $consumer = getConsumer();
         $return_to = getReturnTo();
         //$this->response = $consumer->complete($_GET);
         $this->response = $consumer->complete($return_to);
         $_SESSION['openid_response'] = serialize($this->response);
     }
     if ($this->response->status == Auth_OpenID_CANCEL) {
         if ($debug) {
             icms_core_Debug::message(_CORE_OID_STATCANCEL);
         }
         // This means the authentication was cancelled.
         $this->setErrors('100', _CORE_OID_VERIFCANCEL);
     } elseif ($this->response->status == Auth_OpenID_FAILURE) {
         if ($debug) {
             icms_core_Debug::message(_CORE_OID_SERVERFAILED);
         }
         $this->setErrors('101', _CORE_OID_FAILED . $this->response->message);
         if ($debug) {
             icms_core_Debug::message(_CORE_OID_DUMPREQ);
             icms_core_Debug::vardump($_REQUEST);
         }
         return FALSE;
     } elseif ($this->response->status == Auth_OpenID_SUCCESS) {
         // This means the authentication succeeded.
         $this->displayid = $this->response->getDisplayIdentifier();
         $this->openid = $this->response->identity_url;
         $sreg_resp = Auth_OpenID_SRegResponse::fromSuccessResponse($this->response);
         $sreg = $sreg_resp->contents();
         $_SESSION['openid_sreg'] = $sreg;
         if ($debug) {
             icms_core_Debug::message(_CORE_OID_SERVERSUCCESS);
             icms_core_Debug::message(_CORE_OID_DISPID . $this->displayid);
             icms_core_Debug::message(_CORE_OID_OPENID . $this->openid);
             icms_core_Debug::message(_CORE_OID_DUMPING);
             icms_core_Debug::vardump($sreg);
         }
         $esc_identity = htmlspecialchars($this->openid, ENT_QUOTES);
         $success = sprintf(_CORE_OID_SUCESSFULLYIDENTIFIED, $esc_identity, $this->displayid);
         if ($this->response->endpoint->canonicalID) {
             $success .= sprintf(_CORE_OID_CANONID, $this->response->endpoint->canonicalID);
         }
         /**
          * Now, where are we in the process, just back from OpenID server or trying to register or
          * trying to link to an existing account
          */
         if (isset($_POST['openid_register'])) {
             if ($debug) {
                 icms_core_Debug::message(_CORE_OID_STEPIS . 'OPENID_STEP_REGISTER');
             }
             $this->step = OPENID_STEP_REGISTER;
         } elseif (isset($_POST['openid_link'])) {
             if ($debug) {
                 icms_core_Debug::message(_CORE_OID_STEPIS . 'OPENID_STEP_LINK');
             }
             $this->step = OPENID_STEP_LINK;
         } elseif (isset($_SESSION['openid_step'])) {
             if ($debug) {
                 icms_core_Debug::message(_CORE_OID_STEPIS . $_SESSION['openid_step']);
             }
             $this->step = $_SESSION['openid_step'];
         } else {
             if ($debug) {
                 icms_core_Debug::message(_CORE_OID_CHECKINGID);
             }
             // Do we already have a user with this openid
             $member_handler = icms::handler('icms_member');
             $criteria = new icms_db_criteria_Compo();
             $criteria->add(new icms_db_criteria_Item('openid', $this->openid));
             $users =& $member_handler->getUsers($criteria);
             if ($users && count($users) > 0) {
                 $this->step = OPENID_STEP_USER_FOUND;
                 if ($debug) {
                     icms_core_Debug::message(_CORE_OID_FOUNDSTEPIS . 'OPENID_STEP_USER_FOUND');
                 }
                 return $users[0];
             } else {
                 /*
                  * This openid was not found in the users table. Let's ask the user if he wants
                  * to create a new user account on the site or else login with his already registered
                  * account
                  */
//.........这里部分代码省略.........
开发者ID:nao-pon,项目名称:impresscms,代码行数:101,代码来源:Openid.php


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