How can I add an accordion label to the image caption

The idea is that the image has a caption text but I want to add a label “more info” that when pressed expands like an accordion to provide copyright information.

I want this to be site-wide so additionally wondering if I can add more meta to the image – for example the media library has Title, Caption, Description but what if I want to add Copyright info too?

Any ideas?

1 Comment
  1. You can do this with a simple function using jQuery for accordion and php to fetch the meta data.


This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer