문제

I'm using the EpiTwitter getAuthorizeUrl() for Twitter authorization.

the code :

<?php
include 'EpiCurl.php';
include 'EpiOAuth.php';
include 'EpiTwitter.php';
require_once 'secret.php';

$Twitter = new EpiTwitter($consumer_key, $consumer_secret);
$url = $Twitter->getAuthorizationUrl();
echo '<a href="' .$url. '">Authorize with Twitter</a>';

?>

i keep getting this error

"Woah there!

This page is no longer valid. It looks like someone already used the token information you provided. Please return to the site that sent you to this page and try again … it was probably an honest mistake."

The url looks fine, but just doesn't work.

http://twitter.com/oauth/authorize?oauth_token=

im sure the ?oauth_token= must have a value, but its not being generated!! thanks for the help secrets.php

<?php
$consumer_key ='xxx';
$consumer_secret ='xxx';

?>
도움이 되었습니까?

해결책

Check out your consumer key and secret once again. Maybe you've typed your variable names wrong. If you used the sample code from here straight out of the box, then the variables are $consumer_key and $consumer_secret - lowercase and underscorized, unlike yours.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top