A better way to write this php function

This answer is completely based on the code and help from -KIKO Software. I did have to add in the global ‘$current_user’ for it to work correctly. Also, per @kikosoftware foresight, I added a means to track by year, just in case a user did not visit the site until the same quarter the following … Read more

Unable to do WP_User_Query with meta filter

This isn’t possible, you can’t safely/reliably query the internals of meta value strings that way, and you can’t use it as a form of indirection: You can query for substrings or for whole values, but you can’t query the internals of serialised PHP values without major performance reliability and consistency issues but if you could, … Read more

Find matches of a variable in custom usermeta

You can use WP user query. Assuming that your meta_key is authmeta you can use the following code to find the users with meta key authmeta and value of your $var variable. $user_query = new WP_User_Query( array( ‘meta_key’ => ‘authmeta’, ‘meta_value’ => $var ) );

How to add custom detail page for a Subscriber at Admin Panel

It sounds like maybe you need to add a settings page, (https://developer.wordpress.org/plugins/settings/custom-settings-page/) This would be good if you had something really custom (customer user meta) and a layout that you wanted to keep separate from the regular user pages. Otherwise, why not just link to the core wordpress user pages? Just build your links like … Read more