Skip to main content
Added tag Ubuntu
Link
Source Link

Can't change PHP.ini in my own server

I have a Development platform with magic_quotes_gpc Off, and I can't turn it Off on my Validation server. Both are Ubuntu 11.04 (thought the Validation server is mount under VMWare). The Dev is uses PHP 5.3.6, the Val uses 5.3.2.

I really need to turn it Off on the Validation server. I tried :

  • setting it Off on all lines of all php.ini I met
  • checked in phpInfo that other /etc/php5/apache2/conf.d/*.ini files does not contain magic_quotes config
  • tried a php flag and/or php value in .htaccess
  • even tried ini_set, thought it does'nt work for this PHP version
  • then relaunched the apache server (even using force-reload)

But whatever I try, I still have it On in the phpinfo(), and also have get_magic_quotes_gpc() == 1 when I test it inside the code.

In fact, no modifications of php.ini are taken (tried fopen_url and timezone). But if I rename php.ini to php.pouet, phpinfo() says that no configuration files is used. If I rename it again to php.ini, this file is taken.

This is a Business Symfony 2 application, and using stripslashes everywhere is not an option (too slow and dirty). Escaping is well handled by Doctrine.

I just don't understand what's going on !