Answer the question
In order to leave comments, you need to log in
Setting up .htaccess before hosting a site on the Internet
There is a simple website (product catalog), I am interested in competent .htaccess settings before placing the site on the Internet. Main questions:
1) Do I need to disable error output (php_flag display_errors off)? Is it better to do it in .htaccess or in some php file?
2) Access to which folders should be closed? The folder structure is simple - css, fonts, images, js, inc, templates.
3) What other settings are desirable?
And an additional question: is it worth turning off error output in this way:
ini_set('display_errors', 'Off');
error_reporting(0);
Answer the question
In order to leave comments, you need to log in
I recommend the following settings in php.ini:
error_reporting = E_ALL
display_errors = Off
display_startup_errors = Off
log_errors = On
error_log = "<path_to_error_log_file>"
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question