[Openfirst-cvscommit] SF.net SVN: openfirst: [157] trunk/www/www/inc/headers.php
Brought to you by:
xtimg
From: <xt...@us...> - 2006-06-20 19:04:25
|
Revision: 157 Author: xtimg Date: 2006-06-20 12:04:16 -0700 (Tue, 20 Jun 2006) ViewCVS: http://svn.sourceforge.net/openfirst/?rev=157&view=rev Log Message: ----------- Fix errors when running PHP scripts from command line (as in updatesite.sh) Modified Paths: -------------- trunk/www/www/inc/headers.php Modified: trunk/www/www/inc/headers.php =================================================================== --- trunk/www/www/inc/headers.php 2006-06-20 19:02:33 UTC (rev 156) +++ trunk/www/www/inc/headers.php 2006-06-20 19:04:16 UTC (rev 157) @@ -1,6 +1,6 @@ <?php // Check to see if the browser supports gzip -if(strpos(" " . $_SERVER["HTTP_ACCEPT_ENCODING"], "gzip")) { +if(isset($_SERVER['HTTP_ACCEPT_ENCODING']) && strpos(" " . $_SERVER["HTTP_ACCEPT_ENCODING"], "gzip")) { // Enable gzip compression (this shrinks the size of pages dramatically-- see http://www.whatsmyip.org/mod_gzip_test/ for a test) if (extension_loaded('zlib') && ini_get("zlib.output_compression") == 0) { ob_start("ob_gzhandler"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |