MyBB Community Forums

Full Version: [TUTORIAL]Integrate Twitter Logins with MyBB
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14
Hmm.. I seem to get this error:
[quote]
ERROR: Could not authenticate you.
[quote]
[quote='Infranight' pid='486545' dateline='1270610021']
Hmm.. I seem to get this error:
Quote:ERROR: Could not authenticate you.
[quote]

Did you put your keys where they should be in the scripts?
Yeah, doesn't seem to work though (it redirects me back to callback.php and shows the error).
I'm assuming it's this part:
if ($twuser->id!='') {
	$twid=$twuser->id;
	$twname=$twuser->screen_name;
} else {
	echo '<h2>ERROR: '.$twuser->error.'</h2>';
}
(2010-04-07, 07:29 PM)Infranight Wrote: [ -> ]Yeah, doesn't seem to work though (it redirects me back to callback.php and shows the error).
I'm assuming it's this part:
if ($twuser->id!='') {
	$twid=$twuser->id;
	$twname=$twuser->screen_name;
} else {
	echo '<h2>ERROR: '.$twuser->error.'</h2>';
}

The error message there isn't provided by the script, its relayed from the Twitter service. Something is not right with the auth variables being sent to Twitter so it's erroring out.

Just a random shot in the dark, try clearing cache+cookies.
Amazing Tutorial, thank you very much Smile
what fid16 for
MyBB has experienced an internal SQL error and cannot continue.

SQL Error:
    1054 - Unknown column 'fid16' in 'field list'
Query:
    UPDATE mybb_userfields SET fid16='Yes' WHERE ufid=1 
(2010-04-17, 06:12 PM)siopk Wrote: [ -> ]what fid16 for
MyBB has experienced an internal SQL error and cannot continue.

SQL Error:
    1054 - Unknown column 'fid16' in 'field list'
Query:
    UPDATE mybb_userfields SET fid16='Yes' WHERE ufid=1 

Here is a quote from the tutorial:
Quote:Now go to Configuration>Custom Profile Fields

Note the highest ID number currently listed.

Go to Add New Profile Field

Set the New Field to the following information:

Title: Twitter Token
Desc: Token
Type: Textbox
MaxLength: 65535
FieldLength: 0
Options: [Blank]
Display Order: One more than the ID you noted (Note this new number as well)
Required: No
Editable: No
Hide: Yes

Save this field and Add another

Set the New Field to the following information:

Title: Twitter Secret
Desc: Secret
Type: Textbox
MaxLength: 65535
FieldLength: 0
Options: [Blank]
Display Order: One more than the second ID you noted (Note this new number as well)
Required: No
Editable: No
Hide: Yes

Save this field and Add another

Set the New Field to the following information:

Title: Registered with Twitter
Desc: Registered
Type: Textbox
MaxLength: 65535
FieldLength: 0
Options: [Blank]
Display Order: One more than the third ID you noted (Note this new number as well)
Required: No
Editable: No
Hide: Yes

Save this field

Keep those three new IDs in a safe place for later.

Upload the callback.php file from the attached archive to your forum root. Edit the file where necessary.
NOTE: fid13, fid14 and fid15 should be changed with their respective fid numbers that you noted down, in order(Only replace the number part, leave fid there).
got it working on http://rangla.net/twlogin.php
test it

Solution in callback.php
change fid16 to you third fid[Number you noted]
can you also help me make facebook login on forum
i see you have it on your own website
similarly please if can make a tutorial i will be really greatfull
The way I perform Facebook Connect integration has a level of complexity that would not take kindly to being transformed into a tutorial. Also, due to several edits to MyBB scripts, upgrade paths are limited without remaking the entire solution.

Because of this, there will most likely never be a tutorial until the solution is simplified and I do not generally implement the solution 1-to-1 with others.
Pages: 1 2 3 4 5 6 7 8 9 10 11 12 13 14