author | Dan |
Sat, 28 Feb 2009 14:38:10 -0500 | |
changeset 847 | 28d5049803f1 |
parent 846 | 0d2d0dfbe443 |
child 848 | b33241a7cc28 |
includes/http.php | file | annotate | diff | comparison | revisions |
--- a/includes/http.php Thu Feb 26 01:28:18 2009 -0500 +++ b/includes/http.php Sat Feb 28 14:38:10 2009 -0500 @@ -214,7 +214,8 @@ $newline = "\r\n"; $php_ver = PHP_VERSION; - $this->add_header('User-Agent', "PHP/$php_ver (Server: {$_SERVER['SERVER_SOFTWARE']}; automated bot request)"); + $server = ( isset($_SERVER['SERVER_SOFTWARE']) ) ? "Server: {$_SERVER['SERVER_SOFTWARE']}" : "CLI"; + $this->add_header('User-Agent', "PHP/$php_ver ({$server}; automated bot request)"); } /**