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


PHP Auth_OpenID_setNoMathSupport函数代码示例

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


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

示例1: Auth_OpenID_include_init

function Auth_OpenID_include_init()
{
    if (Auth_OpenID_getMathLib() === null) {
        Auth_OpenID_setNoMathSupport();
    }
}
开发者ID:rb26,项目名称:zenphoto,代码行数:6,代码来源:OpenID.php

示例2: Auth_OpenID_getMathLib

/**
 * {@link Auth_OpenID_getMathLib} checks for the presence of long
 * number extension modules and returns an instance of
 * {@link Auth_OpenID_MathWrapper} which exposes the module's
 * functionality.
 *
 * Checks for the existence of an extension module described by the
 * result of {@link Auth_OpenID_math_extensions()} and returns an
 * instance of a wrapper for that extension module.  If no extension
 * module is found, an instance of {@link Auth_OpenID_MathWrapper} is
 * returned, which wraps the native PHP integer implementation.  The
 * proper calling convention for this method is $lib =
 * Auth_OpenID_getMathLib().
 *
 * This function checks for the existence of specific long number
 * implementations in the following order: GMP followed by BCmath.
 *
 * @return Auth_OpenID_MathWrapper $instance An instance of
 * {@link Auth_OpenID_MathWrapper} or one of its subclasses
 *
 * @package OpenID
 */
function Auth_OpenID_getMathLib()
{
    // The instance of Auth_OpenID_MathWrapper that we choose to
    // supply will be stored here, so that subseqent calls to this
    // method will return a reference to the same object.
    static $lib = null;
    if (isset($lib)) {
        return $lib;
    }
    if (Auth_OpenID_noMathSupport()) {
        $null = null;
        return $null;
    }
    // If this method has not been called before, look at
    // Auth_OpenID_math_extensions and try to find an extension that
    // works.
    $ext = Auth_OpenID_detectMathLibrary(Auth_OpenID_math_extensions());
    if ($ext === false) {
        $tried = array();
        foreach (Auth_OpenID_math_extensions() as $extinfo) {
            $tried[] = $extinfo['extension'];
        }
        $triedstr = implode(", ", $tried);
        Auth_OpenID_setNoMathSupport();
        $result = null;
        return $result;
    }
    // Instantiate a new wrapper
    $class = $ext['class'];
    $lib = new $class();
    return $lib;
}
开发者ID:ookwudili,项目名称:chisimba,代码行数:54,代码来源:BigMath.php

示例3: define

 * Status code returned when there were no OpenID arguments
 * passed. This code indicates that the caller should return a 200 OK
 * response and display an HTML page that says that this is an OpenID
 * server endpoint.
 *
 * @see Auth_OpenID_Server
 */
define('Auth_OpenID_DO_ABOUT', 'do_about');
/**
 * Defines for regexes and format checking.
 */
define('Auth_OpenID_letters', "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ");
define('Auth_OpenID_digits', "0123456789");
define('Auth_OpenID_punct', "!\"#\$%&'()*+,-./:;<=>?@[\\]^_`{|}~");
if (Auth_OpenID_getMathLib() === null) {
    Auth_OpenID_setNoMathSupport();
}
/**
 * The OpenID utility function class.
 *
 * @package OpenID
 * @access private
 */
class Auth_OpenID
{
    /**
     * Return true if $thing is an Auth_OpenID_FailureResponse object;
     * false if not.
     *
     * @access private
     */
开发者ID:Kraiany,项目名称:kraiany_site_docker,代码行数:31,代码来源:OpenID.php


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