User Meta stuff

You have a few PHP issues preventing output- it appears your foreach is commented out with //. you do foreach( $our_children as $children ), but then you use $our_children instead of $children inside the foreach. $children->Age is for accessing an object’s property, but what you have here is an array, so it should be $children[‘Age’] … Read more

Change User Role based on Point System Issue

You have to remove the previous role first, then add the new role like $u = new WP_User( $user_ID); $role_of_user= $u->roles[0]; $u->remove_role($role_of_user); $u->add_role(‘new_role’); If user has more than 1 role then $u = new WP_User( $user_ID); foreach($u->roles as $role){ $u->remove_role($role); } $u->add_role(‘new_role’);

Get user ID when action row link is clicked

I am passing the user ID as user via the link so its show in my custom list table url. For example, admin.php?page=history_logger&user=3 The user ID is in the query variable. You can access it using a PHP global variable. $_GET[‘user’] $user_id = $_GET[‘user’]; Do not assume that this request (link) came from the Users … Read more

Making WordPress available while logged into another website

The function wp_authenticate is pluggable, meaning you can override it with a function of your own of the same name. You could rewrite that to contact your “self-hosted, secure, members-only website” for logins instead of using the WordPress login system. There are other pluggable functions in that file, like wp_validate_auth_cookie, which may prove useful with … Read more

Assigning multiple or additional capabilities to specific users or how to create additional roles like bbpress roles?

In WordPress is pretty simple create custom roles and also assign specific capabilities to specific user roles (no matter if from core or custom). In my plugins I often create an user role that has all the capabilities required by my plugin, and then I attach some of thos capabilities to existing roles. I’ll give … Read more

One Click Access To Users Account In WordPress?

What do you mean by “takes them to the users account as if they’re the user”? Do you mean allow someone to log in as another WP user? If so then I think you are looking for a plugin like the User Switching plugin. That plugin only allows administrators to “switch” to another user. http://wordpress.org/plugins/user-switching/

How can I set wp_dropdown_users so that it shows only authors?

you can create a function which gives you all users which have role author in a drop down list. Note: It is a dummy example modify it as you want( put this function in functions.php or custom plugin ). Use: Call this function any where in theme like <?php ravs_author_dropdown_list(); ?> function ravs_author_dropdown_list() { // … Read more

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)