• Resolved jhdean

    (@jhdean)


    Hello David,

    Is it possible with Media Library Assistant to create a shortcode that uses variables and formulas which could be used in a generic page template that when called from a link on any primary image thumbnail in a gallery. would capture the thumbnail image file name or id in a variable and use it as the primary image on the target page, and then, using tag filters and/or terms common to the primary and detail images file names, generate a gallery of related detail images along with their titles, captions and descriptions also on the page? Being able to have a generic page that could be linked to from any image and then be populated through a formula based on the selected image would be a huge time saver and avoid the necessity of creating individual detail pages for every set of images in a portfolio.

    Thanks,
    Jeff

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

Viewing 5 replies - 16 through 20 (of 20 total)
  • Thread Starter jhdean

    (@jhdean)

    Thanks for the clarification David,

    I think I have found the cause of so many misinterpreted “tax query error” messages and I am rather mystified.

    Whenever I change the double quotes in <div class="detail-title"> to single quotes and save, in this case a Divi text module, I can preview and it works but when I update and then open the module again, the quotes are back to double quotes??? This is in the Text editor not the Visual editor.

    Have you come across this before? Any ideas?

    Thanks,
    Jeff

    Plugin Author David Lingren

    (@dglingren)

    Thanks for your update. I am not sure what a “Divi text module” is, but the general issue of these unwanted “improvements” in post/page content comes from a number of sources.

    I have found that, for example, switching from the “Text” tab to the “Visual” tab and back to “Text” will immediately cause the problem. There may be other times/places where the “improving” happens without your control or consent. If you can be more specific about your example I can try to reproduce it.

    Thread Starter jhdean

    (@jhdean)

    Divi is a theme from Elegant themes with a drag and drop type of page builder which is very handy. I checked in a standard editor and didn’t have the problem. This issue seems to be related to the Divi theme page builder so I will look into it with them.

    thanks,
    Jeff

    Plugin Author David Lingren

    (@dglingren)

    Thanks for the additional information.

    This should have occurred to me much earlier, but I finally thought of another way to avoid the problem. It is fine to use single quotes to delimit the shortcode parameters, leaving you free to use double quotes within the parameter for your HTML attributes. For example:

    [mla_gallery ids=2027 mla_caption='<div class="detail-title">{+template:({+page_title+})+}</div><br>?<br>{+template:({+description+}|{+caption+})+}' link=none size=large]

    This works on my test system and the “Text”-“Visual”-“Test” tab changing doesn’t cause any damage. I am confident you can use it with the Divi theme editor as well. Good luck!

    Thread Starter jhdean

    (@jhdean)

    Brilliant, you are correct. The Divi editor is only changing double quotes in the HTML attributes.

    Thanks,
    Jeff

Viewing 5 replies - 16 through 20 (of 20 total)
  • The topic ‘Generic shortcode for page generated from thumbnail link’ is closed to new replies.