News:

SMF 2.1.4 has been released! Take it for a spin! Read more.

Main Menu

Fatal error uploading attachments

Started by Glenn Sand, March 27, 2006, 10:56:23 AM

Previous topic - Next topic

Glenn Sand

SMF Version: SMF 1.1 RC2

My board has been up an running for about a week now.  This is the first problem I've found.

While trying to upload an image as an attachment to a post, I get the following message on a white screen:

Fatal error: Call to undefined function: exif_imagetype() in /home/admin/public_html/forums/Sources/Post.php on line 1479

I have many many mods installed and suspected that something in the installation of them corrupted this file.  So, I uploaded a fresh copy of the post.php file and overwrote the 'corrupt' file thinking that it would solve the problem.  That didn't work.

Any ideas on what to do next?

[nofollow]

kegobeer

Did you host compile PHP with exif support?  If not, then that would explain why the function is failing.  While you're at it, verify your host compiled PHP with GD2.
"The truth of the matter is that you always know the right thing to do. The hard part is doing it." - Norman Schwarzkopf
Posting and you (Click "WATCH THIS MOVIE")

Glenn Sand

#2
You lost me at "Did you"
Please explain how I check for these things and how to fix them if they're not as they should be.

[nofollow]

kegobeer

You need to see if your host enabled exif support in PHP.  You can do this by creating a phpinfo script, uploading it to your site, and running it.


<?phpphpinfo();?>


Look for exif.  If you don't see it, you don't have exif support.  Do the same for GD.  Alternatively, you can ask your host if you have exif and GD support.
"The truth of the matter is that you always know the right thing to do. The hard part is doing it." - Norman Schwarzkopf
Posting and you (Click "WATCH THIS MOVIE")

Glenn Sand

#4
Quote from: kegobeer on March 27, 2006, 12:12:23 PMLook for exif.  If you don't see it, you don't have exif support.  Do the same for GD.  Alternatively, you can ask your host if you have exif and GD support.

You were absolutely correct.  Once they enabled the exif library (GD was already enabled), the problem went away.  Thanks for the tip.

Glenn

[nofollow]

Advertisement: