I am in need of just one or two extra fields in the Membership2 registration process (BuddyPress is not an option for several reasons), so I installed Cimy User Extra Fields, which (according to this post) is compatible and supported by M2.
Per the above article, I created a mu-plugin. Then, I had to vary the instructions due to the total revamp of M2 since that article was written. There is no /membership/membershipincludes/includes/account.form.php that I could find. So instead I added
to a template I created called content-extra_fields.php, and called it as the template part (in place of content-page.php) in m2-account.php, per the new M2 customization features.
This basically works, but I ran into a couple problems.
1) The extra field I created is a dropdown. On the /account page for a logged in user, the field displays *as a dropdown* and includes the whole list of other selections. What I want is just to display the value of that field for the logged in user.
2) Additionally, on the /account page, it’s basically just a dump of all the data for that entire extra field. It includes the description and even the word “REQUIRED”. This does not make sense on a read-only page.
3) According to the article, this:
add_action('edit_user_profile_update', 'cimy_update_ExtraFields'); in a mu-plugin
should permit editing of the Cimy field. However, on the edit profile page (/account/?action=edit_profile) the user sees the editable field and can change it….but the change does not “stick”. When the /account page re-displays, the field has not changed.
I would love to get this working. It’s very close to solving a huge challenge I’ve been dealing with.
Thanks in advance!