kanazaca/laravel-steam-auth
最新稳定版本:1.1.4
Composer 安装命令:
composer require kanazaca/laravel-steam-auth
包简介
Laravel Steam Auth
README 文档
README
This package is a Laravel 5 service provider which provides Steam OpenID and is very easy to integrate with any project which requires steam authentication.
Installation Via Composer
Add this to your composer.json file, in the require object:
"kanazaca/laravel-steam-auth": "1.1.*"
After that, run composer install to install the package.
Add the service provider to app/config/app.php, within the providers array.
'providers' => array( // ... 'kanazaca\LaravelSteamAuth\SteamServiceProvider', )
Lastly, publish the config file.
php artisan vendor:publish
Usage
use kanazaca\LaravelSteamAuth\SteamAuth; class SteamController extends Controller { /** * @var SteamAuth */ private $steam; public function __construct(SteamAuth $steam) { $this->steam = $steam; } public function getLogin() { if( $this->steam->validate()){ return $this->steam->steamInfo; //returns the user steam info }else{ return $this->steam->redirect(); //redirect to steam login page } } }
Credits
- invisnik (original maintainer)
统计信息
- 总下载量: 57
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 2
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2015-03-30