in reply to Re: Conditional statement problem
in thread Conditional statement problem

Yes, Rob it was the image causing the problem although I'm still not clear why as the image did get returned if the cookie was set. But I swiped the following subroutine code to print the image and now the program works fine. Thanks.
my $image = 'logo.gif'; open(IMAGE, "<$image") or die "cannot open image file: $!"; my $no_bytes = (stat ($image))[7]; print "Content-type: image/gif\n"; print "Content-length: $no_bytes\n"; print "Pragma: no-cache\n\n"; print <IMAGE>; close(IMAGE) or die "cannot close image file: $!";