function OAuthRequest::calculateDataSignature in Lingotek Translation 7.2
Same name and namespace in other branches
- 7.3 lib/oauth-php/library/OAuthRequest.php \OAuthRequest::calculateDataSignature()
* Calculate the signature of a string. * Uses the signature method from the current parameters. * *
Parameters
string data: * @param string consumer_secret * @param string token_secret * @param string signature_method * @exception OAuthException2 thrown when the signature method is unknown * @return string signature
2 calls to OAuthRequest::calculateDataSignature()
- OAuthRequest::calculateSignature in lib/
oauth-php/ library/ OAuthRequest.php - * Calculate the signature of the request, using the method in oauth_signature_method. * The signature is returned encoded in the form as used in the url. So the base64 and * urlencoding has been done. * *
- OAuthRequestSigner::sign in lib/
oauth-php/ library/ OAuthRequestSigner.php - * Sign our message in the way the server understands. * Set the needed oauth_xxxx parameters. * *
File
- lib/
oauth-php/ library/ OAuthRequest.php, line 219
Class
- OAuthRequest
- Object to parse an incoming OAuth request or prepare an outgoing OAuth request
Code
function calculateDataSignature($data, $consumer_secret, $token_secret, $signature_method) {
if (is_null($data)) {
$data = '';
}
$sig = $this
->getSignatureMethod($signature_method);
return $sig
->signature($this, $data, $consumer_secret, $token_secret);
}