A big thank you to everyone. The problem was that I had
zlib.output_compression = On in php.ini Turning this off allowed proper parsing and output of index.php
I think this should be mentioned somewhere in the install documentation, or in the FAQ, or both. I searched the forum and found reference to this problem. These other posts reference pretty much the same problem:
http://forum.coppermine-gallery.net/index.php?topic=4888.0http://forum.coppermine-gallery.net/index.php?topic=1457.0http://forum.coppermine-gallery.net/index.php?topic=1642.0http://forum.coppermine-gallery.net/index.php?topic=9182.0and a few others more recent that I can't find now.
I am somewhat confused as to whether the apache gzip compression of output (mod_deflate module) is different to the zlib compression. I think I have the apache compression turned on, but am not sure (??), this is from httpd.conf:
# AddEncoding allows you to have certain browsers (Mosaic/X 2.1+) uncompress
# information on the fly. Note: Not all browsers support this.
#
AddEncoding x-compress Z
AddEncoding x-gzip gz tgz
But I have not myself enabled compression, by the method in apache documentation ( SetOutputFilter DEFLATE : will enable compression for documents in the container where it is placed) [ what is a container? ]
Also, I did some of my own debugging on index.php in the only way I know, cutting code. I found that the binary junk was produced from code within the
$elements = [/i] function on line 682. If any of the following
case functions were present, I got the binaries:
case 'catlist':
case 'alblist':
case 'random':
case 'lastup':
BUT, every other
case allowed proper display of the index.php page [ and these other case functions included the flush() statements ]. I think this might have been caused by the presence of information (and uploaded photos) in categories list, album list, random, last uploaded; and the
lack of information in the other cases (toprated, etc.).
If you cannot use zlib compression, please put that in the install documentation. Also could I get an answer about whether one can use mod_deflate in apache for gzip output? (Or maybe it is not really necessary?) Thanks!
Thanks again everyone. Hopefully I can get Coppermine working with PunBB now!
James