Completely unexpected exception: Call to undefined function exif_imagetype()

22 views
Skip to first unread message

Meropi Petraki

unread,
Sep 3, 2019, 11:58:29 AM9/3/19
to flyspray
flyspray 1.0 rc9
I'm trying to change the logo image and I'm getting this error: 
Completely unexpected exception: Call to undefined function exif_imagetype()
This should never happend, please inform Flyspray Developers

With Regards,
Meropi Petraki

Meropi Petraki

unread,
Sep 4, 2019, 1:53:26 AM9/4/19
to flyspray
Solved. I changed in the code includes/modify.inc.php the following line
if( in_array(exif_imagetype($_FILES['logo']['tmp_name']), array(IMAGETYPE_GIF, IMAGETYPE_JPEG, IMAGETYPE_PNG)) ) {
to this:
if(array(IMAGETYPE_GIF, IMAGETYPE_JPEG, IMAGETYPE_PNG)) {

Francesco Giordano

unread,
Sep 4, 2019, 2:04:41 AM9/4/19
to flyspray
Hi Meropi Petraki,

>if(array(IMAGETYPE_GIF, IMAGETYPE_JPEG, IMAGETYPE_PNG)) {

That's basically like removing the IF statement completely :)
A better solution would be to check your PHP configuration if you have mbstring and exif support enabled

Regards,
F.
Reply all
Reply to author
Forward
0 new messages