Forum Replies Created

Viewing 1 replies (of 1 total)
  • Thread Starter tjb1187

    (@tjb1187)

    Hi sorry for the delayed response, I was off line for a while. I’m trying to filter results by multiple fields.

    I have a post type named ‘boats’ and I would like to fetch results based a field named ‘length’ and ‘make’. I have tailored the example code you provided on the plugin page. Lets say I was looking for a boat that length=58 and make=viking, I am doing the following:

    fetch( 'https://domain.com/wp-json/wp/v2/boats?filter[meta_query][0][key]=length&filter[meta_query][0][value]=58&filter[meta_query][1][key]=make&filter[meta_query][1][value]=Viking')

    But this returns nothing. Could you please help? Is there something I’m missing.

    Thanks

Viewing 1 replies (of 1 total)