I’m stuck ::: I’m trying to use a URL variable’s value in the ACF Taxonomy Query :::
For instance I have the following URL :
bozo.com/listing/?location=san-francisco&type=14
I now need to use the value “14” in the following function :::
How can I do this ?
// Frontend Type Taxonomy
$type_id = $_GET('type');
function ydcoza_type_acf_taxonomy( $args, $field, $post_id ) {
global $type_id;
$args['child_of'] = $type_id;
// return
return $args;
}
add_filter('acf/fields/taxonomy/query/key=field_5a76bfb425b99', 'ydcoza_type_acf_taxonomy', 10, 3);