Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have sharring hosting account on Linux Apache PHP with JustHost.

In my account exists a global php.ini that only admin of hosting company can access.

My problem is that when I run php script the warnings + errors printed on webpage.

So I create php.ini in my www folder and put 2 lines, but nothing happens:

display_errors = Off
display_startup_errors = Off

What should I do to override the global shared hosting php.ini settings?

share|improve this question

2 Answers 2

up vote 2 down vote accepted

Try putting these lines in your .htaccess file:

php_value display_errors 0
php_value display_startup_errors 0
share|improve this answer

Possible, your hosting provider restricts you from overriding default php.ini. Not always!

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.