Added detection of finfo class for server running PHP 4.