Titles In Photo Galleries

To have titles appear under the images in a photo gallery, follow these steps:

  1. When uploading the images to the photo gallery, put the text you want to show up under the images in the 'title' field
  2. After you've finished and added the asset to a page, go to code view and paste the following inside the 'footcode' tags:

    <script>
    $(document).ready(function() {
       $(".thumbnails > li > .thumbnail > img").each(function() {
         var caption = $(this).attr("alt");
         $(this).parent().after('<p class="caption">'+caption+'</p>');
       });
       $(".thumbnails").addClass("captions");
    });
    </script>
  3. Then save a publish
©