How do I add some miscellaneous userdata? When each user registers they should be automatically assigned an identicon. I was thinking I'd read the userdata using get_profile_info_keys() but I can't find a corresponding set_profile_info_keys() or the like. Does anyone know?
bbPress support forums » Plugins
Setting user data
(7 posts)-
Posted 1 year ago #
-
Hmm perhaps add an hidden field with basic assignment in it?
Wasn't there a plugin in the works that did something like this? Adding custom fields it was...
Null
Posted 1 year ago # -
It shouldn't be that hard, I was looking at the avatar plugin and it just added an extra field to the info keys when the user edited the profile. I guessed from that that bb automatically took all the info from that and made that extra data entry in the database.
But in this case there's nothing the users can specify. :PPosted 1 year ago # -
Does anyone know?
Posted 1 year ago # -
I would take a look at the custom profile plugin because it is subscribes to adding custom fields to be added to the usermeta table and gets pulled when you view the profile. It might give you a hint!
Trent
Posted 1 year ago # -
Unfortunately not, as it simply hangs itself on the
get_profile_info_keysfilter - so it gives extra values for the user to edit, which isn't what I'm looking for.Posted 1 year ago # -
To set one yourself is a lot harder than should be. If you look in the database, you'll see that all that information is held in a single linear table called usermeta.
What you want to do is make a script that, upon creation of a user, adds something to that table. You'll have to do the dirty work yourself. It's not THAT hard, but not as easy as what you're wanting.
My avatar plugin simply adds the avatar to the list, which allows the user to set the value. You can't add something into that list without the user being able to set the value (your only choices are required and not required).
Posted 1 year ago #
Reply
You must log in to post.