• Resolved Andry

    (@blackstar1991)


    I need to add Custom Field – “City” for account page.

    I find that Country we can and like this –

    function um_account_custom_fields($args, $shortcode_args)
    {
        $args .= ',country';
        $args .= ',city';
        return $args;
    }
    
    add_filter('um_account_tab_general_fields', 'um_account_custom_fields', 10, 2);

    But it doesn’t work for custom field… How to fix it?

Viewing 9 replies - 1 through 9 (of 9 total)
  • Thread Starter Andry

    (@blackstar1991)

    Can you please help ? I created this field into registration form with meta key = user_city but I don’t understand how to add it into general Tab in Account page.

    Plugin Support andrewshu

    (@andrewshu)

    Hello @blackstar1991

    Sorry, but customizations are not included in our support.

    Regards.

    Thread Starter Andry

    (@blackstar1991)

    Why would you give the option to set a custom field if you don’t give the option to display the field?

    This functionality is not working

    • This reply was modified 1 year, 2 months ago by Andry.
    Plugin Support andrewshu

    (@andrewshu)

    Hi,

    You could get value with this code:

    get_user_meta( $user_id, 'user_city', true);

    Regards.

    Thread Starter Andry

    (@blackstar1991)

    Sorry, but it dosen’t work.

    I added this code for page-account.php but it show nothing. There is no new field on the General tab.

    Plugin Support andrewshu

    (@andrewshu)

    Hi @blackstar1991

    Did you set up the $user_id? Sorry, but customizations are not included in our support. I gave you the direction, but you have to find the solution yourself.

    Regards.

    Thread Starter Andry

    (@blackstar1991)

    @andrewshu

    Ok, thanks. Can you answer alse can I add an editable field on this tab? ‘general’?

    Plugin Support andrewshu

    (@andrewshu)

    Hello @blackstar1991

    Yes you could. But it takes a lot of work.

    Regards.

    Plugin Support andrewshu

    (@andrewshu)

    Hi @blackstar1991

    This thread has been inactive for a while so we’re going to go ahead and mark it Resolved.

    Please feel free to re-open this thread if any other questions come up and we’d be happy to help. ??

    Regards

Viewing 9 replies - 1 through 9 (of 9 total)
  • The topic ‘How to add field City for account page’ is closed to new replies.