/**
* --------------------------------------------------------------------------
* Base Site URL
* --------------------------------------------------------------------------
*
* URL to your CodeIgniter root. Typically this will be your base URL,
* WITH a trailing slash:
*
* http://example.com/
*
* If this is not set then CodeIgniter will try guess the protocol, domain
* and path to your installation. However, you should always configure this
* explicitly and never rely on auto-guessing, especially in production
* environments.
*
* @var string
*/
public $baseURL = (ENVIRONMENT === 'production')
? "http://appname.networkname.local/"
: ((ENVIRONMENT === 'development')
? "http://appname.local/"
: "");
1条答案
按热度按时间tcomlyy61#
解决方案:
1.编辑档案:
app/Config/App.php
1.在 “开发” 和 “生产” 环境中,编辑文件:
.env
并注解掉下面的变量声明:**注意:**我希望您不要使用任何版本控制系统(例如Git)来提交
.env
文件。因为如果项目在以后从一个简单的内部应用程序发展成熟,这可能会导致敏感凭据暴露给公众。