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 mysite.com and sub.mysite.com

php.ini is set to display_errors=off

but for sub.mysite.com which is a testing site, I want display_errors=on

how do I do that?

share|improve this question

2 Answers 2

up vote 1 down vote accepted

I found the solution

Add this to the .htaccess file in the root of the subdomain

php_flag display_errors on
share|improve this answer

This really comes down to your specific php.ini setup. You may be able to, depending upon your configuration, to inject into the .htaccess and/or into a local site php.ini file the settings you want to show.

If your using cPanel (may work with others as well) try the following:

# cp -pv /usr/local/lib/php.ini /home/username/public_html/php.ini
# chown -v username:username /home/username/public_html/php.ini

Keep in mind if safe mode is enabled - than this will not work. PHP link: http://www.php.net/manual/en/configuration.changes.php

share|improve this answer
    
I don't have cPanel –  jax Dec 9 '10 at 9:37

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.