本文整理汇总了PHP中RequestUtil::buildUrlForGetOrPut方法的典型用法代码示例。如果您正苦于以下问题:PHP RequestUtil::buildUrlForGetOrPut方法的具体用法?PHP RequestUtil::buildUrlForGetOrPut怎么用?PHP RequestUtil::buildUrlForGetOrPut使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类RequestUtil
的用法示例。
在下文中一共展示了RequestUtil::buildUrlForGetOrPut方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: _getAuthorizeUrl
protected function _getAuthorizeUrl($redirectUri, $state, $forceReapprove = false)
{
if ($forceReapprove === false) {
$forceReapprove = null;
// Don't include it in the URL if it's the default value.
}
return RequestUtil::buildUrlForGetOrPut($this->userLocale, $this->appInfo->getHost()->getWeb(), "1/oauth2/authorize", array("client_id" => $this->appInfo->getKey(), "response_type" => "code", "redirect_uri" => $redirectUri, "state" => $state, "force_reapprove" => $forceReapprove));
}
示例2: _getAuthorizeUrl
protected function _getAuthorizeUrl($redirectUri, $state)
{
return RequestUtil::buildUrlForGetOrPut($this->userLocale, $this->appInfo->getHost()->getWeb(), "1/oauth2/authorize", array("client_id" => $this->appInfo->getKey(), "response_type" => "code", "redirect_uri" => $redirectUri, "state" => $state));
}
示例3: buildUrlForGetOrPut
/**
* Build a URL for making a GET or PUT request. Will add the "locale"
* parameter.
*
* @param string $host
* Either the "API" or "API content" hostname from {@link getHost()}.
* @param string $path
* The "path" part of the URL. For example, "/account/info".
* @param array|null $params
* URL parameters. For POST requests, do not put the parameters here.
* Include them in the request body instead.
*
* @return string
*/
function buildUrlForGetOrPut($host, $path, $params = null)
{
return RequestUtil::buildUrlForGetOrPut($this->userLocale, $host, $path, $params);
}