Thanks for an interesting application question. You can accomplish your goal with a bit of PHP code that divides the overall query into separate queries for each term and then combines the results.
I have uploaded a new MLA Development Version dated 20160804 that contains a new example plugin with the required code. It also contains a completely new way to find and install example plugins, which I would love your feedback on. To get the Development Version, follow the instructions in this earlier topic:
Shortcode not working in (special) widget
It would be great if you can install the Development Version and let me know how it works for you.
To find the example plugin, navigate to the Settings/Media Library Assistant Documentation tab and click the new “Example Plugins” button. Enter “multi” in the text box and click “Search Plugins”. You should see two example plugins.
The “MLA Multiple WP Query Example” plugin is the one you want. You can hover over the plugin name and click the “Install” rollover action to add it to your site. Then, go to the Plugins/Installed Plugins admin submenu, find the plugin and activate it.
Once the example plugin is activated you can modify your shortcode to be:
[mla_gallery multi_wp_query="gallerytags=flowers,plants,trees,nature" mla_markup=my-markup-slider numberposts=1 orderby=date order=DESC]
The changes are:
- The
gallerytags
taxonomy query has been changed to use the example plugin’s new parameter.
- The
numberposts
parameter has been changed; it applies to each of the four separate term queries.
- The
orderby=date
and order=DESC
parameters have been added to select “the latest” item in each term.
You can inspect (or modify) the plugin code by clicking the “Download” rollover action to get a copy on your local system. You can find more information in the “The Example Plugins” section of the Documentation tab.
I look forward to your comments on the new MLA features and the example plugin. I will leave this topic unresolved until I hear back from you.