Symfony2 php.ini [英] Symfony2 php.ini

查看:73
本文介绍了Symfony2 php.ini的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在使用app/check.php进行检查时,Symfony2表示此Configuration file used by PHP : /etc/php5/cli/php.ini,但是phpinfo();显示Apache正在使用/etc/php5/apache2/php.ini.

When checking with app/check.php Symfony2 says this Configuration file used by PHP : /etc/php5/cli/php.ini however phpinfo(); displays that Apache is using /etc/php5/apache2/php.ini.

我尝试搜索,但找不到解决方案.有人可以解释我如何告诉我的Symfony2应用程序使用Apache2的php.ini吗?还是有什么明显的我想念的地方?

I tried searching but couldn't find a solution. Could someone explain how do I tell my Symfony2 app to use Apache2's php.ini? Or is there something obvious I am missing here?

我是Symfony的新手

I am new to Symfony

推荐答案

PHP cli使用的不是PHP Apache,而是另一个ini.这种情况经常发生(您通常还需要其他配置).

PHP cli uses another ini than PHP apache. That happends quite often (you often also want other configuration).

当您同时从控制台(命令)和apache(应用程序)使用Symfony时,应确保两个ini文件均已为Symfony正确配置.

When you use Symfony from both console (the commands) and apache (the app), you should make sure both ini files are correctly configured for Symfony.

在浏览器中,您可以转到web/config.php以查看有关您的PHP设置等的Symfony报告.

In the browser, you can go to web/config.php to see a report of Symfony about your PHP settings and such.

这篇关于Symfony2 php.ini的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆