コード例 #1
0
ファイル: OAuth.php プロジェクト: harriswong/AContent
 function __construct($key, $secret, $callback_url = NULL)
 {
     // check if the consumer is registered
     $oAuthServerConsumersDAO = new OAuthServerConsumersDAO();
     $consumer = $oAuthServerConsumersDAO->getByConsumerKeyAndSecret($key, $secret);
     if (!is_array($consumer)) {
         throw new OAuthException('Consumer is not registered.');
     } else {
         $this->key = $key;
         $this->secret = $secret;
         $this->callback_url = $callback_url;
     }
 }