I’ve seen the below in someones .htaccess file. How important are they please? Does the hash at the beginning mean something? If so, why would there be 2 on 1 line?
#php_flag allow_url_fopen On
#php_flag allow_url_include On
#php_flag allow_url_fopen 1
#php_flag allow_url_include 1
##php_flag display_errors On
#php_flag display_errors Off
A typo most likely. My guess is it was already commented out and the person just added a hash in front of all the directives, so that one ends up with 2.
Yes, it doesn’t really matter much. Everything after the first one in a line is a comment.
I don’t know what Apache means by “flag” - log the info? I would do the settings in the php.ini file eg. (note, the semi-colons start comments)
; Whether to allow the treatment of URLs (like http:// or ftp://) as files.
; http://php.net/allow-url-fopen
allow_url_fopen = Off
; Whether to allow include/require to open URLs (like http:// or ftp://) as files.
; http://php.net/allow-url-include
allow_url_include = Off
Is it better to have any/all of these in the .htaccess file, or is it better to have any/all of them in the php.ini ?
php_flag allow_url_fopen On
php_flag allow_url_include On
php_flag allow_url_fopen 1
php_flag allow_url_include 1
php_flag display_errors On
php_flag display_errors Off