News Feed
Sections




News Archive
feed this:

Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

James Morris' Blog:
How to Strip EXIF Data Using Imagick
August 25, 2011 @ 10:42:33

James Morris has a quick tutorial today showing how to pull the exif data from a photo and make it into something useful you can either display on on the site or store for categorization.

Today I spent a good amount of time trying to figure out how to strip exif data from an image using Imagick. The first port of call was the (pathetic) documentation at php.net. I searched for 'exif' but found nothing. [...] I was tipped off by a colleague to the method Imagick::stripImage() which apparently did what I wanted. The only mention of exif is in a rather helpful comment at the bottom of the page.

This comment pointed him to the Imagick::stripImage() function that pulls off the data and returns exif information (or, as the documentation calls it, "profiles and comments"). His seven line script is included in the post that initializes the Imagick object, pulls in the file and runs the stripImage() method with the option for "exif:*". The resulting properties are then displayed including aperature value, date taken, exposure time, make and model of the camera, shutter speed, resolution and much more.

0 comments voice your opinion now!
tutorial image exif data imagick stripimage


Vanessa Vasile's Blog:
Using PHP to Extract Image Exif Data
August 03, 2010 @ 08:40:12

In a new post to her blog Vanessa Vasile shows how to use PHP to extract EXIF data from images with the help of the Exif extension.

Those of us fluent in digital photography have come across the term 'Exif data' numerous times when it comes to software we use to digitally manipulate photographs. Exif (Exchangeable image file format) data is generally used to identify the properties of the camera that snapped a picture, and usually the software that altered it afterwards. [...] This quick tutorial will demonstrate how to extract Exif data from an image using PHP.
She talks about enabling the extension (if it's not already there), using it to check the image type, reading the header data and using it to great a thumbnail based on the image type.

0 comments voice your opinion now!
exif extension data tutorial image


Zend Developer Zone:
Reading and Writing MP3 and Photo Metadata with PECL
November 11, 2008 @ 08:44:45

The Zend Developer Zone has a new tutorial from Vikram Vaswani looking at the reading and writing of metadata for mp3s and images with two handy PECL extensions.

It's just that every time I sit down to have a go at [finding something in my photo or mp3 library], the sheer volume of data overwhelms me and I take the command decision to deal with something easier instead. Sounds familiar? If it does, help is at hand, in the form of PHP's ID3 and EXIF extensions. These extensions can help you organize and catalog your digital media collection so that it's easier to navigate and search. Keep reading, and I'll show you how.

He installs the ID3 package first (via the pecl command line tool) and gives a few sample scripts to pull the metadata information out of a mp3 file as well as update/remove the information that's already there. He even sets up a simple SQLite database to store the information he's retrieved.

The second part of the tutorial looks at grabbing the image metadata via the EXIF extension. This can yield all sorts of information including date/time the photo was taken, the resolution, the model of the camera and various camera settings at the time. He includes a sample script that automatically makes thumbnails for the images via the exif_thumbnail function.

0 comments voice your opinion now!
pecl package id3 exif mp3 photo metadata tutorial


SitePoint PHP Blog:
Ubuntu Add-Ons with PHP
August 16, 2006 @ 07:18:05

In his latest post on the SitePoint PHP blog today, Harry Fuecks talks about a problem he was having - adding comments to pictures to be stored with them, not seperately. He's found a solution and it involves g-scripts.

One particular problem is adding comments to images; most archiving software (like gthumb) has you store stuff seperately from the images, maintaining their own databases (in the case of gthumb, under ~/.gnome2/gthumb). But I'd rather have comments stay with the image (e.g. using Exif - there are other ways but Exif wins on being widely supported).

He talks about the use of the g-scripts and something called Zenity to make the popup inputs for the comments. After some quick tips to be sure everything's set up, he demonstrates how to, with PHP scripts and Zenity, to integrate the comments into the Exif data of your files.

0 comments voice your opinion now!
ubuntu picture comment exif data integrate gscripts zenity ubuntu picture comment exif data integrate gscripts zenity



Community Events





Don't see your event here?
Let us know!


version language symfony update package framework library community introduction mvc laravel tool opinion security release interview voicesoftheelephpant series composer podcast

All content copyright, 2014 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework