Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author David Lingren

    (@dglingren)

    Yes, there are two ways to display the description contents in your [mla_gallery].

    First, you can use the mla_caption parameter to replace the default caption displayed for gallery items. For example, you can add mla_caption="{+caption+}: {+description+}" to your shortcode to display both the caption and the description values. That’s an easy way to accomplish your goal.

    Of course, the second way would be to code a custom markup template. The “Table-based Template Example” in the documentation shows how to do this.

    One of those solutions should work for you. Let me know if you have any further questions or problems with them.

    Thread Starter pcusack

    (@pcusack)

    Hi David,

    I have tried inserting your suggestion into my shortcode and the result displayed on the website is:

    [+caption+]: TEST DESCRIPTION

    SHORTCODE #1 USED IS:
    [mla_gallery post_mime_type=application/pdf attachment_category=small_business_series_basic link=file mla_target=_blank mla_viewer=true columns=2 mla_viewer_width=200 orderby=title DESC mla_caption=”{+caption+}: {+description+}”]

    In contrast, without inserting the mla_caption parameter you have suggested, the result I get is the “Caption” that I have identified for any selected item in the Media Library.

    SHORTCODE #2 USED IS:
    [mla_gallery post_mime_type=application/pdf attachment_category=small_business_series_basic link=file mla_target=_blank mla_viewer=true columns=1 mla_viewer_width=400 orderby=title DESC]

    Using the Shortcode #2, my temporary solution is to simply combine my “Caption” and “Description” into the Caption Field in the Media Library in order to see the desired results on the web page.

    Is my Shortcode #1 not correct? Ideally separating the Caption and Description in the Media Library would be preferred.

    Plugin Author David Lingren

    (@dglingren)

    You’ve exposed a little defect in the current version of the plugin. The “caption” value isn’t calculated until after the mla_caption substitution is made. I will fix this in the next release. In the interim, you can substitute {+excerpt+] for {+caption+} and get the results you want.

    Sorry for the confusion (and the bug)!

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Gallery Descriptions displayed in Shortcode?’ is closed to new replies.