g4를 g5로 변경
This commit is contained in:
@ -9,8 +9,8 @@ include_once("./_common.php");
|
||||
|
||||
/* Start session and load lib */
|
||||
//session_start();
|
||||
require_once(G4_SNS_PATH.'/twitter/twitteroauth/twitteroauth.php');
|
||||
require_once(G4_SNS_PATH.'/twitter/twitterconfig.php');
|
||||
require_once(G5_SNS_PATH.'/twitter/twitteroauth/twitteroauth.php');
|
||||
require_once(G5_SNS_PATH.'/twitter/twitterconfig.php');
|
||||
|
||||
//print_r2($_SESSION); print_r2($_REQUEST); exit;
|
||||
|
||||
@ -43,8 +43,8 @@ if (200 == $connection->http_code) {
|
||||
exit;
|
||||
*/
|
||||
|
||||
$g4['title'] = '트위터 콜백';
|
||||
include_once(G4_PATH.'/head.sub.php');
|
||||
$g5['title'] = '트위터 콜백';
|
||||
include_once(G5_PATH.'/head.sub.php');
|
||||
|
||||
if (200 == $connection->http_code) {
|
||||
$content = $connection->get('account/verify_credentials');
|
||||
@ -54,7 +54,7 @@ if (200 == $connection->http_code) {
|
||||
set_cookie('ck_sns_name', $sns_name, 86400);
|
||||
set_session('ss_twitter_user', $sns_user);
|
||||
|
||||
$g4_sns_url = G4_SNS_URL;
|
||||
$g5_sns_url = G5_SNS_URL;
|
||||
|
||||
echo <<<EOT
|
||||
<script>
|
||||
@ -63,7 +63,7 @@ if (200 == $connection->http_code) {
|
||||
|
||||
var opener = window.opener;
|
||||
opener.$("#wr_name").val("{$sns_name}");
|
||||
opener.$("#twitter_icon").attr("src", "{$g4_sns_url}/icon/twitter.png");
|
||||
opener.$("#twitter_icon").attr("src", "{$g5_sns_url}/icon/twitter.png");
|
||||
opener.$("#twitter_checked").attr("disabled", false);
|
||||
opener.$("#twitter_checked").attr("checked", true);
|
||||
window.close();
|
||||
@ -84,5 +84,5 @@ EOT;
|
||||
|
||||
}
|
||||
|
||||
include_once(G4_PATH.'/tail.sub.php');
|
||||
include_once(G5_PATH.'/tail.sub.php');
|
||||
?>
|
||||
|
||||
@ -9,7 +9,7 @@ include_once("./_common.php");
|
||||
/**
|
||||
* Exit with an error message if the CONSUMER_KEY or CONSUMER_SECRET is not defined.
|
||||
*/
|
||||
require_once(G4_SNS_PATH.'/twitter/twitterconfig.php');
|
||||
require_once(G5_SNS_PATH.'/twitter/twitterconfig.php');
|
||||
if (CONSUMER_KEY === '' || CONSUMER_SECRET === '' || CONSUMER_KEY === 'CONSUMER_KEY_HERE' || CONSUMER_SECRET === 'CONSUMER_SECRET_HERE') {
|
||||
echo 'You need a consumer key and secret to test the sample code. Get one from <a href="https://dev.twitter.com/apps">dev.twitter.com/apps</a>';
|
||||
exit;
|
||||
|
||||
@ -8,8 +8,8 @@ include_once("./_common.php");
|
||||
|
||||
/* Load required lib files. */
|
||||
//session_start();
|
||||
require_once(G4_SNS_PATH.'/twitter/twitteroauth/twitteroauth.php');
|
||||
require_once(G4_SNS_PATH.'/twitter/twitterconfig.php');
|
||||
require_once(G5_SNS_PATH.'/twitter/twitteroauth/twitteroauth.php');
|
||||
require_once(G5_SNS_PATH.'/twitter/twitterconfig.php');
|
||||
|
||||
/* If access tokens are not available redirect to connect page. */
|
||||
if (empty($_SESSION['access_token']) || empty($_SESSION['access_token']['oauth_token']) || empty($_SESSION['access_token']['oauth_token_secret'])) {
|
||||
|
||||
@ -3,8 +3,8 @@ include_once("./_common.php");
|
||||
|
||||
/* Start session and load library. */
|
||||
//session_start();
|
||||
require_once(G4_SNS_PATH.'/twitter/twitteroauth/twitteroauth.php');
|
||||
require_once(G4_SNS_PATH.'/twitter/twitterconfig.php');
|
||||
require_once(G5_SNS_PATH.'/twitter/twitteroauth/twitteroauth.php');
|
||||
require_once(G5_SNS_PATH.'/twitter/twitterconfig.php');
|
||||
|
||||
/* Build TwitterOAuth object with client credentials. */
|
||||
$connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET);
|
||||
|
||||
@ -6,5 +6,5 @@
|
||||
|
||||
define('CONSUMER_KEY', $config['cf_twitter_key']);
|
||||
define('CONSUMER_SECRET', $config['cf_twitter_secret']);
|
||||
define('OAUTH_CALLBACK', G4_SNS_URL.'/twitter/callback.php');
|
||||
define('OAUTH_CALLBACK', G5_SNS_URL.'/twitter/callback.php');
|
||||
//define('OAUTH_CALLBACK', '');
|
||||
|
||||
Reference in New Issue
Block a user