in reply to weird GIF problem

Most likely, you're on Windows. You should always (even on Unixish OSes, nowadays) use binmode on filehandles you're reading that are not supposed to contain text:

open ($myimage, '<', $imagelocation) or die "cannot open '$imagelocation': $!"; binmode $myimage; ...

Replies are listed 'Best First'.
Re^2: weird GIF problem
by roadnottaken (Acolyte) on Jan 03, 2009 at 21:46 UTC
    THANKS! That worked. I knew it was something like that and I tried all manner of binmode(STDOUT) and binmode(STDIN) to no avail. Much appreciated.