Hi @brening
Have you tried the following?
$data['default'] = um_user("my_key");
UM()->fields()->edit_field(‘my_key’, $data );
Regards,
Small part of my code:
$fields = array('my_key');
$data = [];
foreach ($fields as $field) {
$data[$field] = UM()->builtin()->get_specific_field($field);
}
$data = apply_filters('um_account_secure_fields', $data, $User_id);
UM()->fields()->edit_field('my_key', $data['my_key']);
-
This reply was modified 5 years, 3 months ago by
brening.
Hi @brening
Does it work? Are you trying to create fields in the Account form?
Regards,
Yes, this code works for other fields. I output a form for entering user data.
Hi @brening
Thanks for letting us know. I am closing this thread now.
Regards,
No, it doesn’t work for select field.
Hello! I got it wrong. My problem is still relevant. Can you help?
Hi @brening
Sorry for the late response.
Could you please tell us if you’re still having issues?
Feel free to re-open this thread by changing the topic status to “Not Resolved” so that we can get back to you.
Regards,