diff options
author | cash <cash.costello@gmail.com> | 2011-12-17 21:52:20 -0500 |
---|---|---|
committer | cash <cash.costello@gmail.com> | 2011-12-17 21:52:20 -0500 |
commit | aae0fa0c6762d25e048c297156f8969c6242eb11 (patch) | |
tree | a29d26529a26a7ae850a0cea5ce107814325043b /classes | |
parent | aa9ed6f3eb46fb9508692d1b5d92c717c3648527 (diff) | |
download | elgg-aae0fa0c6762d25e048c297156f8969c6242eb11.tar.gz elgg-aae0fa0c6762d25e048c297156f8969c6242eb11.tar.bz2 |
added support for OpenID 1.x
Diffstat (limited to 'classes')
-rw-r--r-- | classes/ElggOpenIDConsumer.php | 20 |
1 files changed, 16 insertions, 4 deletions
diff --git a/classes/ElggOpenIDConsumer.php b/classes/ElggOpenIDConsumer.php index 864e47d41..3918086ab 100644 --- a/classes/ElggOpenIDConsumer.php +++ b/classes/ElggOpenIDConsumer.php @@ -142,13 +142,17 @@ class ElggOpenIDConsumer { $url = "http://$username.blogspot.com/"; break; case 'wordpress': - $url = ""; + // username is actually the blog name + $url = "http://$username.wordpress.com/"; + break; + case 'livejournal': + $url = "http://$username.livejournal.com/"; break; case 'aol': - $url = "http://openid.aol.com/$username"; + $url = "https://openid.aol.com/"; break; case 'verisign': - $url = "http://username.pip.verisignlabs.com/"; + $url = "https://pip.verisignlabs.com/ "; break; case 'myopenid': $url = 'https://myopenid.com/'; @@ -204,6 +208,8 @@ class ElggOpenIDConsumer { * the provider. If JavaScript is not enabled, a plain html form with a * continue button is displayed. * + * This also supports OpenID 1.x but has not been tested as thoroughly. + * * @return mixed */ protected function getForm() { @@ -213,7 +219,13 @@ class ElggOpenIDConsumer { return $html; } else { // OpenID 1.x - return false; + $redirect_url = $this->request->redirectURL(elgg_get_site_url(), $this->returnURL); + + if (Auth_OpenID::isFailure($redirect_url)) { + return false; + } else { + forward($redirect_url); + } } } |