config.php push 안되는 문제로 twitter/config.php 를 twitter/twitterconfig.php 로 파일명 변경

This commit is contained in:
gnuboard
2013-05-28 16:30:20 +09:00
parent 3c311fa669
commit 04810bb8f9
7 changed files with 16 additions and 6 deletions

View File

@ -49,7 +49,7 @@ if ($_POST['facebook_checked']) {
//----------------------------------------------------------------------------
if ($_POST['twitter_checked']) {
include_once(G4_SNS_PATH."/twitter/twitteroauth/twitteroauth.php");
include_once(G4_SNS_PATH."/twitter/config.php");
include_once(G4_SNS_PATH."/twitter/twitterconfig.php");
if ( !(empty($_SESSION['access_token']) || empty($_SESSION['access_token']['oauth_token']) || empty($_SESSION['access_token']['oauth_token_secret'])) ) {
$post = googl_short_url($comment_url).' '.$wr_content;

View File

@ -10,7 +10,7 @@ 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/config.php');
require_once(G4_SNS_PATH.'/twitter/twitterconfig.php');
//print_r2($_SESSION); print_r2($_REQUEST); exit;

View File

@ -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/config.php');
require_once(G4_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;

View File

@ -9,7 +9,7 @@ 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/config.php');
require_once(G4_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'])) {

View File

@ -4,7 +4,7 @@ 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/config.php');
require_once(G4_SNS_PATH.'/twitter/twitterconfig.php');
/* Build TwitterOAuth object with client credentials. */
$connection = new TwitterOAuth(CONSUMER_KEY, CONSUMER_SECRET);

View File

@ -0,0 +1,10 @@
<?php
/**
* @file
* A single location to store configuration.
*/
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', '');

View File

@ -48,7 +48,7 @@ if (!$board['bo_use_sns']) return;
//----------------------------------------------------------------------------
if ($config['cf_twitter_key']) {
include_once(G4_SNS_PATH."/twitter/twitteroauth/twitteroauth.php");
include_once(G4_SNS_PATH."/twitter/config.php");
include_once(G4_SNS_PATH."/twitter/twitterconfig.php");
$twitter_user = false;
if (empty($_SESSION['access_token']) || empty($_SESSION['access_token']['oauth_token']) || empty($_SESSION['access_token']['oauth_token_secret'])) {