By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
457,915 Members | 1,331 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 457,915 IT Pros & Developers. It's quick & easy.

Fatal error: Call to undefined function: imagecreatefromjpeg() in...

P: n/a

I am getting a "Fatal error: Call to undefined function:
imagecreatefromjpeg() in..." error in one of my scripts, and after doing
a bit of searching on the 'net I found various messages relating to a
failure to have the GD library installed. However, my phpinfo() reports
(in the Apache GD section):

GD Support enabled
GD Version bundled (2.0 compatible)
GIF Read Support enabled
PNG Support enabled
WBMP Support enabled
I tried running a configure/make/make install with the following
configure command line...

../configure --with-mysql --with-apxs2
--with-zlib-dir=/etc/rpms/php-4.3.1/ext/zlib --with-png
--with-png-dir=/usr/lib --with-jpeg --with-jpeg-dir=/usr/lib --with-gd

....with no change in status.

What puzzles me is that phpinfo() also reports...
Configure Command './configure' '--with-mysql' '--with-apxs2'
.... not reflecting the options I specified.

I suspect I am doing something VERY wrong (i.e. stupid) -- but am not
sure where to look next.

HELP!!!

-dh

------------------------------------------------
Dan Hansen
------------------------------------------------
Jul 16 '05 #1
Share this Question
Share on Google+
5 Replies


P: n/a
A horsie named Daniel Hansen demonstrated surprising intelligence and its
ability to use morse code on Thu, 11 Sep 2003 22:54:13 -0500 when it
tapped <6i********************************@4ax.com> with its hoof:

[...]
I tried running a configure/make/make install with the following
configure command line... [...]

What puzzles me is that phpinfo() also reports...
Configure Command './configure' '--with-mysql' '--with-apxs2'
... not reflecting the options I specified.


Perhaps your httpd.conf is still loading the old version
of the library. When you did "make install," the module
might have been installed in a different place than
the original library was.

If that's so, you would have to change httpd.conf to
reflect the location of your new php library; then
stop and start apache.

HTH

Jul 16 '05 #2

P: n/a
On Fri, 12 Sep 2003 08:27:27 GMT, Gary Petersen
<ga*******@remove.meearthlink.invalid>, wrote:
Perhaps your httpd.conf is still loading the old version
of the library. When you did "make install," the module
might have been installed in a different place than
the original library was.

If that's so, you would have to change httpd.conf to
reflect the location of your new php library; then
stop and start apache.


'fraid not -- there are no references to gd or anything seemingly
relevant in my httpd.conf.

Thanks, though!
dh
------------------------------------------------
Dan Hansen
------------------------------------------------
Jul 16 '05 #3

P: n/a

"Daniel Hansen" <dr********@mindspring.com> wrote in message
news:6i********************************@4ax.com...

I am getting a "Fatal error: Call to undefined function:
imagecreatefromjpeg() in..." error in one of my scripts, and after doing
a bit of searching on the 'net I found various messages relating to a
failure to have the GD library installed. However, my phpinfo() reports
(in the Apache GD section):

GD Support enabled
GD Version bundled (2.0 compatible)
GIF Read Support enabled
PNG Support enabled
WBMP Support enabled
I tried running a configure/make/make install with the following
configure command line...

./configure --with-mysql --with-apxs2
--with-zlib-dir=/etc/rpms/php-4.3.1/ext/zlib --with-png
--with-png-dir=/usr/lib --with-jpeg --with-jpeg-dir=/usr/lib --with-gd

...with no change in status.

What puzzles me is that phpinfo() also reports...
Configure Command './configure' '--with-mysql' '--with-apxs2'
... not reflecting the options I specified.

I suspect I am doing something VERY wrong (i.e. stupid) -- but am not
sure where to look next.

HELP!!!

-dh

------------------------------------------------
Dan Hansen
------------------------------------------------


I'm using PHP 4.3.3 with Apache 1.3.28 and have the same problem - My news
posts were a bit behind but I notice you raised the same question before
me - I thought I'd throw in my two pence worth and say that I found
imagecreatefromgif() worked for me, whereas imagecreatefromjpeg() failed
with the same fatal error as yours. I'm wondering if there is a dependancy
on an external jpeg library which you/I might not have installed.
Jul 16 '05 #4

P: n/a

"Daniel Hansen" <dr********@mindspring.com> wrote in message
news:6i********************************@4ax.com...

I am getting a "Fatal error: Call to undefined function:
imagecreatefromjpeg() in..." error in one of my scripts, and after doing
a bit of searching on the 'net I found various messages relating to a
failure to have the GD library installed. However, my phpinfo() reports
(in the Apache GD section):

GD Support enabled
GD Version bundled (2.0 compatible)
GIF Read Support enabled
PNG Support enabled
WBMP Support enabled
I tried running a configure/make/make install with the following
configure command line...

./configure --with-mysql --with-apxs2
--with-zlib-dir=/etc/rpms/php-4.3.1/ext/zlib --with-png
--with-png-dir=/usr/lib --with-jpeg --with-jpeg-dir=/usr/lib --with-gd

...with no change in status.

What puzzles me is that phpinfo() also reports...
Configure Command './configure' '--with-mysql' '--with-apxs2'
... not reflecting the options I specified.

I suspect I am doing something VERY wrong (i.e. stupid) -- but am not
sure where to look next.


I have a post with a similar subject - I've included my compile options that
might help since I *had* the same problem (though phpinfo() did not report
the same as yours, imagecreatefromjpeg() was undefined).
Jul 16 '05 #5

P: n/a

This is what finally worked for me. Not sure whether it was the "make
clean" or adding exif support -- but it worked!

make clean
../configure --with-mysql --with-apxs2 --with-xpm-dir --with-png
--with-png-dir --with-jpeg-dir --enable-exif --with-zlib-dir --with-gd
configure.2003.09.12.dh5.log

make
make install
libtool --finish /etc/rpms/php-4.3.1/libs
apachectl -k stop
service httpd start


On Fri, 12 Sep 2003 22:25:05 GMT, "Randell D."
<yo**************************@yahoo.com>, wrote:
....
....
....
I have a post with a similar subject - I've included my compile options that
might help since I *had* the same problem (though phpinfo() did not report
the same as yours, imagecreatefromjpeg() was undefined).


------------------------------------------------
Dan Hansen
------------------------------------------------
Jul 16 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.