• Resolved BriDanz

    (@bridanz)


    Hello,

    I have 2 issues at the moment:

    First, I cannot seem to get the caption on the first document on the [mla_library] output page(s) to be of the same size as all of the others; it’s always a couple of font sizes larger. I have a screenshot to share, but cannot post it here, unfortunately. I feel like this my be related to the Custom Markup Template I’m using:

    <[+itemtag+] class='gallery-item [+last_in_row+]'>
    	<[+icontag+] class='gallery-icon [+orientation+]'>
    		<a href="[+link_url+]"><img [+custom:Document Image+]></a>
    	</[+icontag+]>
    	<[+captiontag+] class='wp-caption-text gallery-caption'>
    		[+caption+]
    	</[+captiontag+]>
    </[+itemtag+]>

    Second, I cannot get the rollover text ( or “hover text”, not sure I’m using the correct term) to display. My goal here is to have a short description appear when a user rolls-over/hovers their mouse cursor over the document icon. Here is the [mla_library] short code currently in use:

    [mla_gallery post_mime_type=application/pdf post_parent=all link=file mla_style="none" mla_caption="{+description+}" mla_rollover_text="{+caption+}"]

    Any and all help with these issues is greatly appreciated!

    Regards,

    Brian

    https://www.ads-software.com/plugins/media-library-assistant/

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

    (@dglingren)

    Thanks for posting the template and shortcode source code; very helpful. It looks like you are following the suggestions given in this earlier Support Forum topic:

    Replace MIME-type Icons in [mla_library] with Images

    Is that right? If so, make sure your custom field includes the src= attribute string as well as any other attributes you need. By the way, you can use the new ,raw option to put the whole tag in your custom field if you want to. You could change the relevant line of the template to be:

    <a href="[+link_url+]">[+custom:Document Image,raw+]</a>

    and then put something like < img src=myimage.jpg> in the custom field (omitting the space before “img”).

    In any case, I don’t see how that would cause the issue you report, where the first caption is larger than the others. If the page is accessible by Internet, could you post a link to it so I can see what’s in the HTML markup?

    With regard to your mla_rollover_text issue, you have uncovered a change WordPress made back in version 3.7 which I had not noticed. For some unannounced reason WordPress eliminated the title= attribute in the links returned by the wp_get_attachment_link function. I will make a change in the next MLA version to restore the mla_rollover_text parameter to life, but in the interim you can achieve your goal with a small change to your shortcode:

    [mla_gallery post_mime_type=application/pdf post_parent=all link=file mla_style="none" mla_caption="{+description+}" mla_link_attributes='title="{+caption+}"']

    The last parameter has been changed to add back the title= attribute. Note the use of single quotes surrounding the parameter value so double quotes can be used for the attribute value.

    I regret any inconvenience caused by my failure to track the WordPress change. I will leave this topic unresolved until I make a release that fixes the mla_rollover_text issue. If you can post a link or give me more information on your first (font size) issue I will investigate that further.

    Thanks for your patience and for your interest in the plugin.

    Thread Starter BriDanz

    (@bridanz)

    Hi David, thanks very much for the excellent support of this plugin.

    I have fixed the issue with the caption size of the first doc, and you were correct in that it was not an issue with the custom markup template.

    I have also tried using your workaround suggestion for the rollover text, however I was unsuccessful. Could you please take a look at my shortcode to see if I’m missing something?

    [mla_gallery post_mime_type=application/pdf post_parent=all link=file mla_style="none" attachment_tag=tag1 mla_caption="{+description+}" columns="3" mla_link_attributes='title="{+caption+}"']

    I’m sorry that I can’t give access to the site, I’m developing on my company’s intranet currently.

    Thanks again,

    Brian

    Plugin Author David Lingren

    (@dglingren)

    Brian,

    Thanks for your update; I am glad the caption size issue has been resolved.

    Regarding your rollover text issue, I have copied your shortcode into my test system, eliminated the attachment_tag=tag1 parameter, and everything is working on my system. I get a single-column list of my PDF documents with the Description value in the caption and in the rollover text. If I remove the mla_style="none" parameter I get a three-column display with the same content.

    Can you expand on “I was unsuccessful” and give me more details about what is wrong? It may be a theme/styling problem or some other issue.

    Plugin Author David Lingren

    (@dglingren)

    Brian,

    I have released MLA v1.90, which restores the mla_rollover_text parameter. You can try changing the mla_link_attributes parameter to mla_rollover_text="{+caption+}" if you are still having trouble with your display.

    I am marking this topic resolved, but please update it if you are still having problems or further questions about adding rollover titles to your gallery items. Thanks for your interest in the plugin.

Viewing 4 replies - 1 through 4 (of 4 total)
  • The topic ‘Caption and Rollover/Hover Text in [mla library]’ is closed to new replies.