mordisacks/laravel-force-https
最新稳定版本:1.0.1
Composer 安装命令:
composer require mordisacks/laravel-force-https
包简介
Laravel middleware for forcing https connection
README 文档
README
Install
Require this package with composer using the following command:
composer require mordisacks/laravel-force-https
After updating composer, add the service provider to the providers array in config/app.php
MordiSacks\LaravelForceHttps\ServiceProvider::class,
Laravel 5.5 uses Package Auto-Discovery, so doesn't require you to manually add the ServiceProvider.
To install this package on only development systems, add the --dev flag to your composer command:
composer require --dev mordisacks/laravel-force-https
Usage
Just add forceHttps to your middleware list
Route::group(['middleware' => ['forceHttps']], function () { Route::get('/home', 'HomeController@index')->name('home'); });
Or in a controller
public function __construct() { $this->middleware('forceHttps'); }
统计信息
- 总下载量: 6.72k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 3
- 点击次数: 1
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2018-09-20