We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 36760
    • 136 Posts
    I'm running Revolution 2.3.3 and have a lot of information stored from the registration form in extended fields. Is there a way to show the extended fields with input boxes alongside the normal fields when editing users in the manager (i.e. under the General Information tab, instead of the Extended Fields tab)?

    I read some things about extending modUser, but that seems to be much more robust than what I need. I'm fine with the information being stored in extended fields, I was just hoping to make editing the information a little more intuitive for the people I'm making the site for. The Update Profile page is my backup plan if I can't get it working in the manager.

    I came across this post, and it looks like it might be what I need: http://forums.modx.com/index.php?action=thread&thread=66894&i=1. I wanted to make sure it was before I started spending time on messing around with the code, or see if a different way has come along in the last few years since that post was made. smiley

    As always, I appreciate the help! I've been here a lot lately...

    This question has been answered by BobRay. See the first response.

    • discuss.answer
      • 3749
      • 24,544 Posts
      You might take a look at ClassExtender. It has come out since the post you reference. It will extend the modUser object and display your custom fields on the Create/Edit user form. It will also give you much faster response times when you want to display user information of search by it.

      Using it with Register is a little tricky. After getting things the way you want them with ClassExtender, you need to add a Register postHook to save the fields. The code for that is here. It will be in the next release of ClassExtender. It's easier than it looks, you just paste that code into a snippet and specify that snippet as a postHook in the Register tag.

        Did I help you? Buy me a beer
        Get my Book: MODX:The Official Guide
        MODX info for everyone: http://bobsguides.com/modx.html
        My MODX Extras
        Bob's Guides is now hosted at A2 MODX Hosting
      • Extended fields are stored as a single JSON-encoded string, so actually using it can be a problem, and is slow. Especially searching is nearly impossible.
          Studying MODX in the desert - http://sottwell.com
          Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
          Join the Slack Community - http://modx.org
          • 36760
          • 136 Posts
          Thanks for the responses, I ended up coming across ClassExtender after some more searching yesterday. It was certainly a big help with extending modUser. I had no idea where to start before. I even found the thread where you and another user were discussing the registration posthook. So I got it all working! Definitely a lot nicer than extended fields for what I'm doing.