Jump to content

How to "enable exif"?


Recommended Posts

To say that I am a beginner with this, would be an understatment.  Last night I was at the level of doing a google search for "what is php?"  So please forgive me if my question is stupid.

I want to read exif data from a picture.  I read on "the manual" that in order to use the exif functions I must configure php to "enable exif".

How do I do this?  Remember I am very much a novice?  I need directions that a moron could follow.

I doubt I will be able to answer any questions.  So here is my phpinfo() page if that will help you give me very straitforward directions.  http://www.photography.willandsam.com//test.php

Link to comment
Share on other sites

If this is a shared host or you know nothing about linux contact your host and ask them about enabling the extension.

1) Download the version of PHP you're using
http://museum.php.net/php5/php-5.0.4.tar.gz

2) Extract the contents into whichever directory you choose.
[code]
tar -xzvf php-5.0.4.tar.gz
[/code]

3) Go into the exif directory. The directory name (php-5.0.4) shown in the example below may not be correct.
[code]
cd php-5.0.4/ext/exif/
[/code]

4) run phpize
[code]
phpize
[/code]

5) run configure
[code]
./configure --enable-exif=shared
[/code]

6) run make
[code]
make
[/code]

If you see errors that refer to "mbstring" then you may need to run configure again using the following
[code]
CPPFLAGS='-I../mbstring/' ./configure --enable-exif=shared
[/code]

run make again
[code]
make
[/code]

If it runs fine with no errors. You should see a file in ./modules/ named exif.so

If you've gotten this far, post here saying so as all you need to do now is copy it to the appropriate directory ("extension_dir"), modify the php.ini adding "extension=exif.so" and restart Apache.
Link to comment
Share on other sites

[quote author=shoz link=topic=108344.msg435940#msg435940 date=1158480716]
If this is a shared host or you know nothing about linux contact your host and ask them about enabling the extension.
[/quote]

Thank you very much for your help.

I suspect the host is shared, and I know I know nothing about linux.  I succeeded in step 1...

So I emailed host's tech support, 5 minutes later I got a reply saying exif is now installed.  So I guess it is very easy when you know what you are doing.

Thanks again

Will
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.