You are here

function dropbox_client_access in Dropbox Client 7

Same name and namespace in other branches
  1. 7.4 dropbox_client.module \dropbox_client_access()
  2. 7.2 dropbox_client.module \dropbox_client_access()
  3. 7.3 dropbox_client.module \dropbox_client_access()
1 string reference to 'dropbox_client_access'
dropbox_client_menu in ./dropbox_client.module
Implements hook_menu().

File

./dropbox_client.module, line 169

Code

function dropbox_client_access() {
  module_load_include('php', 'dropbox_client', 'oauth');
  module_load_include('php', 'dropbox_client', 'dropbox');

  //Credential for App Dropbox Client For Drupal
  $params['key'] = D4D_KEY;
  $params['secret'] = D4D_SECRECT;
  $dropbox = new dropbox($params);
  $oauth = $dropbox
    ->get_access_token($_SESSION['dropbox_client_token_secret']);
  $_SESSION['oauth_token'] = $oauth['oauth_token'];
  $_SESSION['oauth_token_secret'] = $oauth['oauth_token_secret'];
  drupal_goto('dropbox_client/sucess');
}