• I want to add a new filter inside members, and to do that, I want to create my own custom field with my own code (not with the default ones) and save it inside um_fields and _um_custom_fields.
    I have to do it that way because I want to save information automatically for each user doing queries to the database.
    What hook is the best to do that?
    Thank you
    https://ibb.co/kMPSWNT

    • This topic was modified 1 year, 10 months ago by pasalomoco.
Viewing 6 replies - 1 through 6 (of 6 total)
  • Thread Starter pasalomoco

    (@pasalomoco)

    is it possible to do a default custom field for users using a query that appears always in their profiles without having to edit the field?

    • This reply was modified 1 year, 10 months ago by pasalomoco.
    • This reply was modified 1 year, 10 months ago by pasalomoco.
    Plugin Support Ultimate Member Support

    (@ultimatemembersupport)

    Hi @pasalomoco

    Did you mean that you want to add a custom field type and not the default UM field types such as ‘text’, ‘select’ etc.?

    Regards,

    Thread Starter pasalomoco

    (@pasalomoco)

    I need to fill a custom field with a query.
    I mean:
    When I click in my custom function inside wp-admin, I convert a user with one specific role and create metauser data from that user.
    I need to show this metauser information inside ultimate member profile user
    Thanks!

    I have this metauser information https://ibb.co/fx8DnVx and I want to put them inside um_fields and _um_custom_fields so I can use it in member filters https://ibb.co/kMPSWNT

    • This reply was modified 1 year, 10 months ago by pasalomoco.
    • This reply was modified 1 year, 10 months ago by pasalomoco.
    Thread Starter pasalomoco

    (@pasalomoco)

    Anyone can help me here?
    Thanks

    Plugin Support Ultimate Member Support

    (@ultimatemembersupport)

    Hi @pasalomoco

    Are they all text fields or with different field types that you’re trying to add?

    You will need to create a field programmatically and then retrieve the post meta “_um_custom_fields” to unserialize it. Add your field in the array and then save the post meta again and then see if it will show in the member directory settings as filter.

    We don’t have a custom code for this at the moment. Let’s see if others in the forum have something similar an share their solution here.

    Thread Starter pasalomoco

    (@pasalomoco)

    It´s only one field.

    So there isn´t any hook to update _um_custom_fields with my query and show them in the member’s directory
    Thanks

    • This reply was modified 1 year, 10 months ago by pasalomoco.
Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘Custom field with my own code’ is closed to new replies.