comparison goodreads/bkp/working/getLoginURL.php @ 6:077b0a0a3e6d

remaining originals according to dependency walk
author Robert Boland <robert@markup.co.uk>
date Thu, 16 Feb 2017 22:29:02 +0000
parents
children
comparison
equal deleted inserted replaced
5:55445b456ad0 6:077b0a0a3e6d
1 <?php
2 header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
3 header("Last-Modified: " . gmdate("D, d M Y H:i:s") . " GMT");
4 header("Cache-Control: no-store, no-cache, must-revalidate");
5 header("Cache-Control: post-check=0, pre-check=0", false);
6 header("Pragma: no-cache");
7 require_once('GoodreadsAPI.php');
8
9 session_start();
10
11 $connection = new GoodreadsAPI(CONSUMER_KEY, CONSUMER_SECRET);
12 $request_token = $connection->getRequestToken(CALLBACK_URL);
13
14 $_SESSION['oauth_token'] = $request_token['oauth_token'];
15 $_SESSION['oauth_token_secret'] = $request_token['oauth_token_secret'];
16
17 $authorize_url = $connection->getLoginURL($request_token);
18
19 echo $authorize_url;
20
21 ?>