opauth / thecity
Opauth 的 The City 策略
dev-master
2013-09-28 20:31 UTC
Requires
- php: >=5.2.0
- opauth/opauth: >=0.2.0
This package is not auto-updated.
Last update: 2024-09-10 05:15:49 UTC
README
Opauth 的 The City 认证策略。
基于 https://developers.facebook.com/docs/authentication/ 实现
开始使用
-
安装 Opauth-TheCity
cd path_to_opauth/Strategy git clone git@github.com:thecity/thecity-php.git TheCity
-
为 The City 创建插件/应用程序(步骤见 https://api.onthecity.org/docs/apps)
- 确保重定向 URI 设置为实际的 OAuth 2.0 回调 URL,通常是
http://path_to_your_app/thecity/int_callback
- 确保重定向 URI 设置为实际的 OAuth 2.0 回调 URL,通常是
-
至少配置
Client ID
和Client Secret
来配置 Opauth-TheCity 策略。 -
将用户直接引导到
http://path_to_opauth/thecity
以进行认证
策略配置
必需参数
<?php 'TheCity' => array( 'client_id' => 'YOUR APP ID', 'client_secret' => 'YOUR APP SECRET', 'scope' => 'SCOPE (ie user_basic)' )
许可协议
Opauth-TheCity 使用 MIT 许可协议
版权所有 © 2013 City Dev Force