What are the correct methods for manipulating and creating users?
There are methods like update_user_meta in user.php.
Then there is the mysterious WP_User class, which mainly just seems to be a place holder but also retrieves some bits from the db like capabilities? I do not think that just updating its properties stores things to the database?
There is also some sort of cache, which I think is just per request? and has potential for grief.
wp_insert_user has a lot going on which I will work through tomorrow. But just after it updates the db it does
new WP_User( $user_id );
and then sets properties on the result, no update. Do they get updated in the db?
And why all the stripslashes? I presume everything is escaped at html or sql output time.
Any pointers to docs would be helpful. The codex mainly just describes the parameters from methods that are obvious from the source code anyway. My impression is that there are are several generations of methods.
(I am trying to write a plugin that will allow users to self register in a multi site but only if they know one of the site passwords. I am new to WordPress and trying to understand the architecture. Have discovered that multi site and normal registration are unrelated code.)