Meta Box
Support › Meta Box AIO › get_current_user_id()Resolved
is it possible?
exanple image
Hi,
It is impossible, the class WP_User_Query does not accept the argument id and if you want to pass a function as a value of an argument, please use the code.
id
'query_args' => array( 'role__in' => 'Administrator', 'include' => get_current_user_id(), ),
And follow the documentation to know the list of accepted arguments. https://developer.wordpress.org/reference/classes/wp_user_query/prepare_query/ https://docs.metabox.io/fields/user/#sample-code