• Resolved redrocksrover2

    (@redrocksrover2)


    Forgive me for not digging deeper into your documentation before asking this, but is it possible to suppress the output of MLA’s inline styles and still be able to use the shortcode? Barring that, how feasible would it be to tap into MLA’s capabilities without using the shortcode (i.e. by calling MLA functions directly to construct wholly custom output)?

    The reason I ask is that I have an existing gallery template that works with my site and is a responsive layout. I’d prefer to avoid recoding and restyling this template to accommodate MLA, but I’d still like to take advantage of your powerful image metadata functions. I’d just prefer to do it in a way that brings less automation and overhead with it- I don’t need the default styles that MLA brings with it at all.

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

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

    (@dglingren)

    Thank you for your interest and for this question. The question of responsive layout has come up before:

    Gallery Layout/Responsiveness

    I would be very interested in anything you come up with that works!

    There are two ways you can suppress the inline styles. First, you can define a custom style template (on the Settings page) that is empty or has just an HTML comment, e.g.,

    <style type='text/css'>
    </style>
    <!-- see mla_gallery_shortcode() in media-library-assistant/includes/class-mla-shortcodes.php -->

    Second, you can code a filter that hooks the following call and returns false:

    apply_filters( 'use_mla_gallery_style', true )

    Either way, I imagine you will have to match the class and id attributes in the [mla_gallery] HTML output to your template. You can do this by examining the default HTML or by defining a custom markup template to compose the output in a way that meets your needs. Have a look at the documentation, and let me know if you have questions or problems.

    As I said, other people have asked about this and I am still looking for good answers that provide responsive output. Are you using a Theme that includes a template, or something of your own design? I would love to share your solution with everyone if that’s possible.

    I am traveling until February 12, so I can’t do too much until I return home. Thanks again for using the plugin and for your patience.

    Plugin Author David Lingren

    (@dglingren)

    I am adding a new value, mla_style=none, to the [mla_gallery] shortcode. You can use this new value to easily and entirely suppress the addition of CSS inline styles to the gallery output.

    The new value will be available in the next release. Thanks again for this suggestion.

    Plugin Author David Lingren

    (@dglingren)

    I have just released version 1.13, which adds the mla_style=none feature outlined in my earlier message. Let me know if you have any issues with the feature, questions or further suggestions.

    Thanks again for your interest, your patience and for using the plugin.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Suppress output of MLA inline styles?’ is closed to new replies.