• Resolved ernstwg

    (@ernstwg)


    Hi. I have a list of custom fields (ACF) in my attachments and like to search for some content in these fields. Perhaps you can help me. Looking forward to hear from you.

    I have a shortcode on a special page for search activities in place

    [mla_gallery s="{+template:({+request:sk+})+}" link=file mla_search_fields=title,name,excerpt,content,alt-text,file,terms]

    and would like to extend it for custom fields

    [mla_gallery s="{+template:({+request:sk+})+}" link=file mla_search_fields=title,name,excerpt,content,alt-text,file,terms multi_search="custom:*='{+template:({+request:sk+})+}'"]
    

    Idea is to give user the opportunity to enter a string which will be searched everywhere.

    I ‘ve seen mla-multi-search-example.php and want to make use of the parameter All Field Names. For now I am searching for a full match, fielda contains ValueA. I am searching for ValueA.

    /search/?sk='Hamburg Eichtalpark'

    I did a simple test as you proposed in the documentation. Content of the log file is:

    [25-Mar-2024 17:29:41] 709 MLACore::mla_plugins_loaded_action() MLA 3.13 () mla_debug_level 0x3
    [25-Mar-2024 17:29:55] 709 MLACore::mla_plugins_loaded_action() MLA 3.13 () mla_debug_level 0x3
Viewing 1 replies (of 1 total)
  • Plugin Author David Lingren

    (@dglingren)

    Thank you for working with me by email to develop and test an enhancement to the MLA Multi-search Example plugin. I have added a new custom:* value to the plugin that uses the “Simple Custom Field Parameters” to search all custom fields that have values for one or more items. The updated example plugin, version 1.04, will be part of my next MLA update.

    I am marking this topic resolved. Thank you for inspiring and helping me with this MLA enhancement.

Viewing 1 replies (of 1 total)
  • You must be logged in to reply to this topic.