I'm using previous_image_link()
and next_image_link()
to show thumbnails in my image.php template page.
I'm surrounding the thumbs with some styling, so need to be able to hide the whole previous image thumb/link block when showing the first attachment.. and the same for the next image link/thumb when displaying the last one.
How can I ascertain whether a first or last image is being displayed using core functions?
(at the moment I'm using a modified version of adjacent_image_link()
that returns not echo's the gubbins, but would like a non-hacky way)