oAuth and SNI addons

25 views
Skip to first unread message

Janis Volbergs

unread,
May 25, 2012, 4:49:52 AM5/25/12
to agile-too...@googlegroups.com
Hi,

Moved oauth, sni to dedicated namespaces out of misc.
They are updated and address a few issues (especially with Facebook).
Usage of misc/lib/Controller/OAuth.php is discouraged and deprecated. Make your adjustments.

new syntax for Facebook oAuth:

$f = $this->add("oauth/Controller_OAuth_Facebook");
$c = $this->add("sni/Controller_SNI_Facebook");

Remember, to reuse Facebook token to perform extra requests, use following syntax:

$f->setSignatureInfo();
$f->setAuthToken($fbtoken["access_token"], $fbtoken["expires"]);

$c = $this->add("sni/Controller_SNI_Facebook");
$c->setOAuth($f);

given, you have stored $fbtoken, which is usually retrieved by:

if ($fbtoken = $f->check())

Rest of the code remains the same.

Regards,
Janis
Reply all
Reply to author
Forward
0 new messages