Home Forums Add-ons Repeater Field Searchable Repeater Fields ? Reply To: Searchable Repeater Fields ?

  • Hi @elliot

    My project is a blog where they will periodically be posting featured weddings. It is a custom with these types of blogs that they will have a list of acknowledgements at the bottom of the post that tells the reader where they got the cake, the flower arrangements and things like that.

    I thought the repeater field would be perfect since the size and contents of the list could differ greatly from post to post.

    Since this can still be easily input via a custom field with a WYSIWYG editor, it’s not worth the time/trouble to figure out how to make the repeater fields searchable for me at this time.

    I -am- still using the repeater field for these same blog posts so that the blogger can create a photo gallery (though in hindsight my client would’ve been better off if I went with the Gallery plugin for this project instead).

    Once I found out the way that repeater fields are stored in the database, mycustomfield_0_mysubfield, mycustomfield_1_mysubfield, and soforth, I thought if I could somehow return a list of those meta_keys so that I could put them in my array of custom fields it might work…

    eg. $custom_fields = array(‘mycustomfield_0_mysubfield’, ‘mycustomfield_1_mysubfield’);

    But it would differ depending on the post… so I’m not sure if that would work. Here is my code: pastebin