• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 619
  • Last Modified:

Adding caption to the thumbnail for WordPress gallery

Hello all experts.

I have this very simple WordPress website.

I have added this regular Gallery to this page: http://bit.ly/YMA3zW

I have added this code to call the Gallery:
[gallery captiontag="dd" ids="145,146,147,148,149,151,152,154,155,156,157,158,159,160,161,162,163,164,165,166,167,168,169,170,171,172,173,174,175,176,177,178"]

Open in new window

The captiontag="dd" is supposed to pull the caption below the individual thumbnails.  And it does.

But, adding that code no longer opens any of the images as an overlay even though I have selected "Link to Media File" for the individual images.  If I remove that bit, captiontag="dd", it works as intended.

This is the CSS that I am using the style the caption, even though this may not be relevant:
.page-id-82 #content #gallery-1 .gallery-item { position:relative; margin-bottom: 40px; }
.page-id-82 #content #gallery-1 .gallery-caption { position:absolute; bottom:4px; text-align:center; width:100%; }
.page-id-82 #content #gallery-1 .gallery-icon { padding:5px 5px 40px 5px; }

Open in new window

Can someone please tell me what is going on...??  This is supposed to be native WordPress code that I am using.

Thanx in advance,

1 Solution
Julian HansenCommented:
The problem is that your href attributes for your images is pointing to this


Instead of this


It is opening the image - if you wait long enough but it opens the WP image gallery page not just the image (first URL above)

Somewhere you need to change it so it links to the actual image.
driven_13Author Commented:
julianH, thanx for the response.

That is the weirdest thing.

If I take out captiontag="dd" the referencing reverts back to the correct one.

I have no idea why this would change the referencing of the Gallery image.

So, I have no idea how to fix this....[:0(

All I want is the caption to show up below the thumbnail image and so figured if I used native WordPress code and not use plugins I am in the clear.

Any ideas....???

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now