Page 1 of 4

[DEV] OAuthorize phpBB (Facebook connect)

Posted: Wed Nov 21, 2012 1:00 am
by paoloumali
This is a simple OAuth implementation for phpBB.

OAuth providers currently supported:
  • Facebook
Short screencast of what it does: http://screencast.com/t/2qihuXO3Rw

Visit this mod's Facebook page if this thread is not enough:

Demo needs some update.

Download:
Download it from GitHub: https://github.com/PaoloUmali/OAuthorize-phpBB

Login?
Allows forum users to quickly login after they've authorized a social provider to be used in forum login.

Registration?
This mod will not skip the default phpBB registration process. This is just an addon and all phpBB registration functionalities stay intact. What this does is more-like an assisted registration. In the future, you may expand it to auto-fill some data that you need in custom profile fields directly from what the OAuth provider shares.

Ideas:
After authorization, you will have their OAuth ID saved in your profile fields table. You can easily use that for several things like avatars, etc.. as that is available as long as you know the ID. If you know how to do custom profile fields in the templates, then good for you.



Features:
1. Allows login using Facebook accounts binded to forum accounts that authorizes it.
2. Easier registration but users will still have to provide a password just in case they have issues with their Facebook account.

User Options:
1. Associate a Facebook account into a forum for quick login.
2. Also possible to deauthorize OAuth providers (Facebook) as needed.

Note that this is just an addon.

Roadmap:
1. Adding more OAuth providers as they all do the same or similar implementation



Modx:
The modx file that comes with it seems working when I tried it. I've never tried the new release AutoMod though.

Requirements:
phpBB needs curl for this to work.

Re: OAuthorize phpBB (Facebook connect)

Posted: Wed Nov 21, 2012 1:20 pm
by Kamahl19
Finally a good, simple FB connect. I like it and look forward to next integrations.

Top phpBB MOD for last year

Re: OAuthorize phpBB (Facebook connect)

Posted: Wed Nov 21, 2012 3:08 pm
by balboag
I'm excited for this! thanks! :D

Re: OAuthorize phpBB (Facebook connect)

Posted: Wed Nov 21, 2012 5:04 pm
by paoloumali
Hi Kamahl, I'm exactly the same person who had a Facebook login before.

Everyone, please feel free to use it as I'm sure it's working.

Re: OAuthorize phpBB (Facebook connect)

Posted: Sat Nov 24, 2012 3:52 pm
by Marc
Hi paoloumali,

please change your title according to the MOD Development Forum rule 3a.

Thank you.

Re: [DEV] OAuthorize phpBB (Facebook connect)

Posted: Mon Dec 03, 2012 6:29 am
by guardianwill
Hey How are you doing? Hoping all is well. I have a live board and still this is something I wanted for awhile and was going to install. I have the latest automod, umil, and phpbb 3.0.11
I ran this through automod and it gave me the ugly red flag top screen and refused to copy the files over. The other items in ucp_register I am sure I can manually edit and follow through. Also, I am sure before we run the sql the info should be changed for the app info am I correct?

My question is, is there a reason the files did not copy over?

...One or more install actions failed. Please review the actions below, make any adjustments and retry. You may continue with the installation even though some of the actions failed. This is not recommended and may cause your board to not function correctly.

Copy not attempted x 11 for the eleven files.

Thanks again for making a mod and allowing php and its security to do its work. The nice thing is, once they become activated like anyone else they simply have to push a button to connect.

Thanks again and any suggestions would be great. Our site is simply a CHD awareness site to help families that learn they will have a child with CHD during their pregnancy or beyond, support and education. Trying to spread this awareness around the world and help so many families even if it is one family at a time. Our hearts go out to them since our little Joseph was born last year with this heart defect. its at http://www.josephstory.org and of course, the blog is the blog and the support is the support community.

Thanks and hope to hear from you soon. Have a great Sunday!

Can we also have a flag to not display the fields in profiles since Our site soes use custom profile fields. If you view mine, there are not many right now its pretty knew and viewed a lot you will see such as diagnosis ect... That would be awesome and custome fields do have a flag to display or not. Thanks and I have no doubt with your skills you will figure that one out. hehehe Thanks again for taking the time to create this mod! Have a great day!

Re: [DEV] OAuthorize phpBB (Facebook connect)

Posted: Mon Dec 03, 2012 11:00 am
by paoloumali
Do it on a test board. Make sure you set your app right. It seems you're forgetting the app domain.

Image

Ignore what is on the database config as that will be used when an ACP module is available.

Set your config in top portion of oauthorize.php file in the root.

For profile fields, take a look at this: https://wiki.phpbb.com/Tutorial.Custom_profile_fields

Re: [DEV] OAuthorize phpBB (Facebook connect)

Posted: Mon Dec 03, 2012 3:37 pm
by guardianwill
Thank you, but the problem persisted when Automod refused to make the necessary copies over on the server side for installation. so I kind of froze asking what to do next. Does the mod get installed with automod? The mod isn't installed et. I believe the app is finished and waiting. I have others using smf and wordpress with their own apps already installed. It seems to be phpbb is the only one without a stable facebook page. Anyway, Is this a diy install or is their a problem with automod? How should I proceed? As Like I said above:
guardianwill wrote:I ran this through automod and it gave me the ugly red flag top screen and refused to copy the files over. The other items in ucp_register I am sure I can manually edit and follow through.
2. Also, I am sure before we run the sql the info should be changed for the app info am I correct?

My question is, is there a reason the files did not copy over?

...One or more install actions failed. Please review the actions below, make any adjustments and retry. You may continue with the installation even though some of the actions failed. This is not recommended and may cause your board to not function correctly.

Copy not attempted x 11 for the eleven files.
paoloumali wrote:Do it on a test board. Make sure you set your app right. It seems you're forgetting the app domain.

Ignore what is on the database config as that will be used when an ACP module is available.

Set your config in top portion of oauthorize.php file in the root.

For profile fields, take a look at this: https://wiki.phpbb.com/Tutorial.Custom_profile_fields

Re: [DEV] OAuthorize phpBB (Facebook connect)

Posted: Mon Dec 03, 2012 7:56 pm
by paoloumali
If you haven't read how automod works, don't use it. Just proceed with manual installation.

Re: [DEV] OAuthorize phpBB (Facebook connect)

Posted: Mon Dec 03, 2012 9:08 pm
by guardianwill
paoloumali wrote:If you haven't read how automod works, don't use it. Just proceed with manual installation.
??? I guess I am confused. Using Phpbb since its development days and then coming to the newly established automod years ago was a blessing. I Guess I do know how to use it since all of my mods--there are many have been installed with automod. When using automod for your mod it redflagged saying there were errors--could not copy your files to their location. Which nothing was copied. I was not really asking you but informing you of a potential bug in your automod installer. and checking in whether I should go ahead and simply copy those files over.

Image

view it here

Sorry for trying to help.

William

Re: [DEV] OAuthorize phpBB (Facebook connect)

Posted: Tue Dec 04, 2012 2:16 am
by guardianwill
Hi All, Finally got it installed, it wasn't to hard figuring the newest automod and the mod install are not liking one another, and it all looks good. I know I can manually login.

But when I connect to the app, accept the app and it tries to return me I get this:

SQL ERROR [ mysql4 ]

Unknown column 'pf_oauth_facebook_id' in 'where clause' [1054]

An SQL error occurred while fetching this page.

Anyone know how to get me past this?

Thanks..

William

Re: [DEV] OAuthorize phpBB (Facebook connect)

Posted: Tue Dec 04, 2012 4:54 pm
by paoloumali
I sincerely ask you just not use the mod.

Re: [DEV] OAuthorize phpBB (Facebook connect)

Posted: Sun Dec 16, 2012 8:16 am
by SwT-CarbonzZ
Im trying this on my testboard but i don't understand a thing about the DIY instructions.

Re: [DEV] OAuthorize phpBB (Facebook connect)

Posted: Mon Dec 17, 2012 4:42 pm
by paoloumali
Which of those you don't understand?

Re: [DEV] OAuthorize phpBB (Facebook connect)

Posted: Mon Dec 17, 2012 5:10 pm
by SwT-CarbonzZ
The whole step what and where you have to fill all these things in.