function TwitterOAuth::__construct in jQuery social stream 8
Same name and namespace in other branches
- 8.2 src/Twitter/TwitterOAuth.php \Drupal\jquery_social_stream\Twitter\TwitterOAuth::__construct()
construct TwitterOAuth object
File
- src/
Twitter/ TwitterOAuth.php, line 65
Class
- TwitterOAuth
- Twitter OAuth class
Namespace
Drupal\jquery_social_stream\TwitterCode
function __construct($consumer_key, $consumer_secret, $oauth_token = NULL, $oauth_token_secret = NULL) {
$this->sha1_method = new OAuthSignatureMethod_HMAC_SHA1();
$this->consumer = new OAuthConsumer($consumer_key, $consumer_secret);
if (!empty($oauth_token) && !empty($oauth_token_secret)) {
$this->token = new OAuthConsumer($oauth_token, $oauth_token_secret);
}
else {
$this->token = NULL;
}
}