PHP 8.3.4 Released!

OAuth::setToken

(PECL OAuth >= 0.99.1)

OAuth::setToken设置令牌和 secret

说明

public OAuth::setToken(string $token, string $token_secret): bool

为后续请求设置令牌和 secret。

参数

token

OAuth 令牌

token_secret

OAuth 令牌 secret。

返回值

true

示例

示例 #1 OAuth::setToken() 例子

<?php
$oauth
= new OAuth(OAUTH_CONSUMER_KEY,OAUTH_CONSUMER_SECRET);
$oauth->setToken("token","token-secret");
?>

add a note

User Contributed Notes

There are no user contributed notes for this page.
To Top