Codeigniter CIBonfire how to change mode from development to production?

人走茶凉 提交于 2019-12-07 10:13:12

问题


I'm creating my first app using CIBonfire and i'm ready to push it to production, but i'm not sure how to change the mode from development to production so that it does not show the profiler stuff in the footer.

I was not able to find it in any of the settings menus or in the documentation. Any help is appreciated.


回答1:


In your index.php file in your CI-Bonfire. you can find this spot here, just change the define('ENVIRONMENT', 'development') into define('ENVIRONMENT', 'production')

 * You can load different configurations depending on your
 * current environment. Setting the environment also influences
 * things like logging and error reporting.
 *
 * This can be set to anything, but default usage is:
 *
 *     development
 *     testing
 *     production
 *
 * NOTE: If you change these, also change the error_reporting() code below
 *
 */
    define('ENVIRONMENT', 'production');


来源:https://stackoverflow.com/questions/17015733/codeigniter-cibonfire-how-to-change-mode-from-development-to-production

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!