Rev 1189 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 1189 | Rev 1206 | ||
---|---|---|---|
Line 58... | Line 58... | ||
58 | $handled = true; |
58 | $handled = true; |
59 | $out['title'] = _L('Login using Facebook'); |
59 | $out['title'] = _L('Login using Facebook'); |
60 | $out['icon'] = OIDplus::webpath(__DIR__,OIDplus::PATH_RELATIVE).'img/main_icon.png'; |
60 | $out['icon'] = OIDplus::webpath(__DIR__,OIDplus::PATH_RELATIVE).'img/main_icon.png'; |
61 | 61 | ||
62 | if (!OIDplus::baseConfig()->getValue('FACEBOOK_OAUTH2_ENABLED', false)) { |
62 | if (!OIDplus::baseConfig()->getValue('FACEBOOK_OAUTH2_ENABLED', false)) { |
63 | $out['icon'] = 'img/error.png'; |
- | |
64 | $out['text'] = _L('Facebook OAuth authentication is disabled on this system.'); |
63 | throw new OIDplusException(_L('Facebook OAuth authentication is disabled on this system.'), $out['title']); |
65 | return; |
- | |
66 | } |
64 | } |
67 | 65 | ||
68 | $target = |
66 | $target = |
69 | "https://www.facebook.com/v8.0/dialog/oauth?". |
67 | "https://www.facebook.com/v8.0/dialog/oauth?". |
70 | "client_id=".urlencode(OIDplus::baseConfig()->getValue('FACEBOOK_OAUTH2_CLIENT_ID'))."&". |
68 | "client_id=".urlencode(OIDplus::baseConfig()->getValue('FACEBOOK_OAUTH2_CLIENT_ID'))."&". |