• Resolved sim89

    (@sim89)


    Hi
    I’m trying to display information from a custom taxonomy field associated with an image via Advanced Custom Field on the image when it is displayed in the lightbox.
    Can you suggest the most straighforward way of doing this?
    Thanks
    Sim

Viewing 15 replies - 1 through 15 (of 15 total)
  • Plugin Author Jordy Meow

    (@tigroumeow)

    Hi @sim89,

    It’s a bit difficult, but I think it would be really nice to have this kind of things possible.

    How would you like this information to be displayed? Where? If it’s replacing the Title or Caption, that would be easy.

    Thread Starter sim89

    (@sim89)

    Hi Jordy
    Thanks for getting back to me. I ended up using a different plugin, as I was on a deadline to get it finished.
    All the best
    Sim

    fleckebk

    (@fleckebk)

    Hi @tigroumeow, I’m also interested in displaying custom fields in the lightbox popup. I think displaying them above or below the title/caption would be great. Are you considering doing this, or can you point me in the direction of how to accomplish this?

    @sim89, would you mind sharing your solution with me in case the plugin author can’t incorporate this into the plugin?

    Thanks!
    Bryan

    Thomas

    (@kywyz)

    Hello Bryan,

    It actually depends on what is the custom field you want to display I think? Is it only one field? Does it vary ( the number of field(s) )?

    Best regards,
    Thomas

    Thread Starter sim89

    (@sim89)

    Hi Bryan
    I ended up using FancyBox – it’s not a WordPress plugin but a JavaScript library that I incorporated into my build process. It’s easy to add custom fields when you add the lightbox code. However, it’s obviously not as user friendly as a plugin.

    Sim

    fleckebk

    (@fleckebk)

    Hi Sim – Thanks for clarifying. I will check that library out.

    Hey Thomas – It would be two fields from ACF, a photo credit txt field, and a link field to point the user to the article the photo showed up in (I have a photo search engine built, and when the user clicks the photo to enlarge in your lightbox, I want them to be able to view the original article it came from).

    Bryan

    Plugin Author Jordy Meow

    (@tigroumeow)

    Hi @fleckebk,

    We could easily implement a WordPress filter to do that, the problem is that now each attribute below the Lightbox has a little icon; but what would happen to those attributes? No icons? Or that’s not important? Can anyone draw/design or find us a visual example?

    fleckebk

    (@fleckebk)

    Hey @tigroumeow,

    For my purposes, I’m not too worried about the icons. I could easily hide/override those via css likely, providing there’s a selector on them.

    Quick mockup of what it could look like > https://ibb.co/dmz99Vz

    Thanks!
    Bryan

    Plugin Author Jordy Meow

    (@tigroumeow)

    But what the mockup would look like in this case? Like here: https://jordymeow.com/collection/offbeat-japan/#mwl-9

    fleckebk

    (@fleckebk)

    I will only be using the title and caption of the photo. The rest of the exif won’t be used, so I suppose, you could use the proposed filter solution to replace the ‘camera’ and ‘lens’ info with my ‘photo credit’ and ‘post link’.

    Something similar to this > https://ibb.co/JyvYKkP

    Plugin Author Jordy Meow

    (@tigroumeow)

    For now, I think that would be the only workable solution, indeed. The text/content itself could be controlled from WordPress filters. Would you like to try that?

    • This reply was modified 6 years ago by Jordy Meow.
    fleckebk

    (@fleckebk)

    Sure, that would be great! Let me know how to implement.

    Thanks,
    Bryan

    Hi @tigroumeow, any time frame on when you think your solution for the custom field filter can be passed along?

    I’m now looking for that same thing. I want to show a link to the post that goes with an image.

    Plugin Author Jordy Meow

    (@tigroumeow)

    Sorry for the late reply, it’s something we are thinking about. Can you let me know every time the kind of fields you would like to actually create? Do you need an icon? Ideally, how would you like to add that field? Is coding fine?

    I would like to gather the information on this thread to add the feature in the best way possible for everyone ??

Viewing 15 replies - 1 through 15 (of 15 total)
  • The topic ‘Display custom field in lightbox’ is closed to new replies.