_s: Simplify image.php:

* Extracts logic in a custom template tag.
* Reduces switching in and out of php in `.entry-meta`.
* Minor code styling changes.

Fixes #233.