• Skip to primary navigation
  • Skip to main content
  • Skip to footer
  • Home
  • About
  • My Blogs
    • Photoblog
    • Knots
    • WP.com tips
kristarella.blog

kristarella.blog

Happiness Engineer at Automattic, lover of knitting, crochet, sci-fi and more

  • Presentations
  • Plugins
    • Exifography
  • Contact
You are here: Home / Exifography

Exifography

Contents
  1. What is Exifography?
    1. Download current version
  2. Installing the plugin
    1. field options
    2. automatically
    3. via shortcodes
      1. fields
      2. for specific (and multiple) images
    4. display to your theme
      1. Display only some fields of the first attached image
      2. Display all fields of a certain image
      3. Display certain fields of a specific image
  3. More Tutorials
  4. Support
  5. Localisation
  6. License
  7. Upgrading from Thesography

What is Exifography?

Exifography displays EXIF data for images uploaded with WordPress. It utilises WordPress’ own feature of storing EXIF fields in the database, and also enables import of latitude and longitude, exposure bias and flash fired EXIF to the database upon image upload.

Exifography was previously named Thesography, and only had auto-insert into posts in the Thesis theme from DIYthemes. The plugin now works the same way across all themes, so I wanted to change the name to increase visibility and understanding of what the plugin does.

I’ve been using EXIF display on my photoblog for some time. I’ve also written a couple of posts about EXIF with WordPress; Geo EXIF data in WordPress and Add image EXIF metadata to WordPress. Some people expressed a desire to see this functionality in a plugin without modifying WordPress files: this is it.

The purpose of this plugin is to make dislaying EXIF data as convenient as possible, while using as much of WordPress’ native image handling as possible — for convenience, forward compatability and because WP image handling has come a long way since its advent.

Download current version

v1.3.1

Installing the plugin

You can use the built in WordPress installer, by searching for “Exifography” in the Plugins > Add New panel, or follow these steps:

  1. Upload the Exifography folder to your wp-content/plugins directory.
  2. Visit the plugins page of your WordPress dashboard and activate the plugin.
  3. Visit the Exifography Options page under Settings in your WordPress dashboard.

EXIF field options

There are 3 ways to specify which fields are displayed:

  1. on the main options page — these are the default options and can be overridden by either of the other two options
  2. individual post options — if you have the default options set, the post options will automatically inherit those, but if you change the options on an individual post it will use these instead, and if you deselect all the options on a post exif won’t display for that post
  3. shortcode options — if you insert a shortcode into a post it will use first the options that you give it, if you don’t give it any it will use the post options, and if there are none of those it will display all the fields available for that image

Display EXIF automatically

Automatic EXIF display inserts the data for the first image attached to the post at the end of the post.

Display EXIF via shortcodes

EXIF data can be displayed anywhere in your posts via shortcodes. Unlike automatic display, you can display EXIF for multiple images when using shortcodes by specifying the ID of the image.

Use the syntax [exif].

By default the shortcode will display the EXIF items set in the post options, if there are none of those it will show all available exif items for the first image attached to the post.

Display certain EXIF fields

To select the fields you want to display use the attribute “show”.

[exif show="aperture,location,shutter"]

The following list contains valid arguments for the attribute “show”.

  • all
  • aperture
  • credit
  • camera
  • caption
  • created_timestamp
  • copyright
  • exposure_bias
  • flash
  • focal_length
  • iso
  • location
  • shutter_speed
  • title
Display EXIF for specific (and multiple) images

To show the EXIF for a specific image and potentially multiple images within a post, use the attribute “id”. To show multiple images, use the whole shortcode multiple times with different IDs.

[exif id="457"]

You can find the shortcode with ID for an image by viewing the image details in the media dialogue. Press this button to bring up the dialogue: .

Then copy the shortcode from the image details and paste it into the post.

Add EXIF display to your theme

You may also add EXIF data to your theme manually using the function exifography_display_exif($options,$imgID);. This can be used within the loop, with or without an image ID, or outside of the loop if an image ID is provided. To make sure that your theme doesn’t break if the plugin is disabled, use this check to check if the function is there before using it.


The function accepts two parameters: the options for the EXIF items to display and the image ID. If no image ID is provided it will default to the first image attached to the post. The options parameters are the same as those for the shortcode parameters.

In Thesography the display function was just called display_exif(); I found this to be too generic, so I’m deprecating it. The old function will still work for a time, but please switch to the new one soon.

Display only some fields of the first attached image
echo exifography_display_exif('aperture,shutter,iso');
Display all fields of a certain image
echo exifography_display_exif('all',457);

or

echo exifography_display_exif('',457);
Display certain fields of a specific image
echo exifography_display_exif('aperture,shutter,iso',457);

More Tutorials

  • IDs and classes in Exifography output
  • Filtering Exifography output
  • Add EXIF to WordPress gallery images
  • Using photo location data

Support

If you need support for this plugin please post it to the WordPress Forums. I will monitor the forum, but if you don’t get a reply please email me the link to your forum thread.

Localisation

Exifography supports language localisation. If you would like to contribute a translation to be included with the plugin please contact me. You can also keep your own translation in your wp-content directory by putting your .mo file in wp-content/languages; it should automatically load from there if the file is called exifography-lang.mo, where “lang” is the appropriate language code for WordPress (you can find yours in the WordPress Codex).

Exifography comes with its own .po file in the plugin’s languages folder, which contains all the translatable strings. You can use this with software, e.g., Poedit, to make your own translation.

Big thanks to Alejandro Herrero for working out the bugs with language file referencing in v1.0.2.

License

Exifography is licensed under the GNU General Public License.

Upgrading from Thesography

Notes on upgrading from Thesography:

  • I have changed some of the exif field parameters back to the way they are saved in the database for efficiency and tidiness in the code. The old parameters will still work, but that’s why they are a bit different in the documentation now.

 

Our little Monty boy had to go to bunny hospital y Our little Monty boy had to go to bunny hospital yesterday. A bit anxious to hear how he's doing this morning. I hope he can come home today 🤞🏻🙏🏻🐰❤️
I had to reset my phone this week, and in the sear I had to reset my phone this week, and in the search for a new wallpaper I remembered this evening spent with my company at Epcot Disney World. Good memories! Loving seeing this on my phone everyday.
#a8cgm #fireworks #epcot #disneyworld
This is my word of the year #resilience I want to This is my word of the year #resilience
I want to bounce back from adversity, and be able to grow even under stress.
#lettering #brushlettering #wordoftheyear #2021
I don't always feel the need for a new notebook in I don't always feel the need for a new notebook in the new year, but I did this year. I'm not really kissing 2020 goodbye and thinking 2021 will be better; I suspect there are plenty more curve balls coming our way, but I am hopeful that my mindset for the year will be strong and resilient.
#bestnine2020 I can't believe there are no bunnie #bestnine2020
I can't believe there are no bunnies! #karate and #lego were definitely a thing though. Personally it wasn't a bad year, I look forward to better times for and with everyone else though 🤞🏻❤️
Swipe for the previous two years' best nines.
#brickheadz #gkrkarate
This silly bird flew into our glass doors today. I This silly bird flew into our glass doors today. It was stunned enough to sit still while I took this photo and checked it wasn't dead, then flew unsteadily away. #straya #prettybutdumb
This is my new friend. He lives in the garage. I'm This is my new friend. He lives in the garage. I'm cool with it as long as he eats any red backs he comes across. #straya #thingsthatdontwanttokillyou
Good holiday investment! @d.symonds and I trying t Good holiday investment! @d.symonds and I trying to stay at least a little active these holidays 👊🏻
Follow on Instagram

Footer

Subscribe to Blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Top Posts & Pages

  • Bible reading printouts
    Bible reading printouts
  • Contact Me
    Contact Me
  • Edit EPS files in Inkscape on Mac
    Edit EPS files in Inkscape on Mac
  • Exifography
    Exifography
  • Whole New Meaning
    Whole New Meaning
  • Custom bible reading plan
    Custom bible reading plan

Follow Me On…

  • Instagram
  • Twitter
  • GitHub
  • LinkedIn
  • YouTube

Categories

Copyright © 2021 · Kristen Symonds · kristarella.blog