From form to wp_query(); the values of the meta-fields of the record that need to be sampled, that is, simply
'meta_query' => array( 'relation' => 'AND', array( 'key' => 'key1', 'value' => $_GET['value1'], ), array( 'key' => 'key2', 'value' => $_GET['value2'], ), ) How to make it so that if an empty value is transferred, records with any value of this field are displayed, that is, change to
'meta_query' => array( 'relation' => 'AND', array( 'key' => 'key1', 'compare' => 'EXISTS' ), array( 'key' => 'key2', 'value' => $_GET['value2'], ), )