winxaito/laravel-https 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

winxaito/laravel-https

Composer 安装命令:

composer require winxaito/laravel-https

包简介

Redirects http requests to https according to the configuration

README 文档

README

Si vous souhaitez lire ce fichier README en français, cliquez ici.

Laravel HTTPS redirection

This package aims to redirect your HTTP requests to HTTPS very simply.

Installation

NB: This package has not been tested below Laravel 5.5

First, use the function below:

composer require winxaito/laravel-https

If you don't use auto-discovery, add the ServiceProvider to the providers array in config/app.php

WinXaito\LaravelHttpsRedirect\LaravelHttpsServiceProvider::class,

If you want to work with the configurations without going through an environment file, run the following command and then edit the config/https-redirection.php file

php artisan vendor:publish --provider="WinXaito\LaravelHttpsRedirect\LaravelHttpsServiceProvider"

How to use it ?

This package works with environment variables in order of priority.
List of constants in order of priority:

  • HTTPS_FORCE: If this value is true, then in all cases the requests will be redirected to HTTPS, otherwise we go to the following constant:
  • HTTPS_PROHIBIT: If this constant is true, the queries will not be redirected, if it is false, then we go to the following constant:
  • APP_ENV: If this constant is production, then we redirect to HTTPS, otherwise we go to the following constant:
  • APP_DEBUG: If the application is not in debug mode, it is redirected to HTTPS, unless HTTPS_PROHIBIT is true. If the application is in debug mode then the address will not be redirected.

By default if no environment variable is defined we have the following values:

  • HTTPS_FORCE = false
  • HTTPS_PROHIBIT = false
  • APP_ENV = production
  • APP_DEBUG = false

Therefore by default the redirection is enabled.

License

The license is GNU GPL3, therefore if you use this you must respect the indications of the license. For proprietary software that would like to use this library without making their source code available, please contact me.

统计信息

  • 总下载量: 29
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 2
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: GPL-3.0-or-later
  • 更新时间: 2018-01-25

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固