Drupal 7 Optimizations, Make it faster in one single line !

I just discovered something today that should interest lots of people :P Did you know Drupal saves each notice and error in his report logs ? If you have a custom script that generates for example 1000 notices, Drupal does 1000 notice database inserts before you get results. The script execution will never fail and you won’t be warned of these.

Notice examples:

Of course, you tell me: “Why don’t you just disable notices ?” Yeah I did it since the beginning but Drupal 7 bootstrap override all your settings you’ve made from server and scripts.

I tried this php.ini setting , not working

I tried this in script headers , not working either

Finally, the only way to get rid of them is to put this magical line into your /drupalroot/sites/default/settings.php

Just because E_ALL will be set by default in PHP 6, Drupal don’t want to use your server settings…

Check your Drupal report log messages guyz, you could be surprised ;)

Leave a Reply

Your email address will not be published.

Post Navigation