ERROR: http://localhost/mensageria/wp-admin/admin-ajax.php
Hi i have a problem with acf/fields/taxonomy/query/key=field_62d02ad58c59f, because when call a function, my field show ERROR 500 in wp-admin/admin-ajax.php and my terms in list not show.
array(
'key' => 'field_62d02ad58c59f',
'label' => 'Clients',
'name' => 'clients',
'type' => 'taxonomy',
'instructions' => '',
'required' => 0,
'conditional_logic' => 0,
'wrapper' => array(
'width' => '25',
'class' => '',
'id' => '',
),
'admin_only' => 0,
'taxonomy' => 'cat_notice',
'field_type' => 'select',
'allow_null' => 0,
'add_term' => 0,
'save_terms' => 1,
'load_terms' => 1,
'return_format' => 'object',
'multiple' => 0,
),
add_filter('acf/fields/taxonomy/query/key=field_62d02ad58c59f', 'my_acf_fields_taxonomy_query', 10, 2);
function my_acf_fields_taxonomy_query( $args, $field, $post_id ) {
// Order by most used.
$args['parent'] = 0;
return $args;
}
Its my code is like exemplo in documention, but my field inside other field/repeater.