Support » Fixing WordPress » Validate user profile when update?

  • Hi all, i want to check a user meta value exist or not when a user updating their profile. If exist then display a message on user profile page. I have use profile_update action but it not as I expected. Anyone can help me?

    Here is my code:

    add_action( 'profile_update', 'my_profile_update' );
        function my_profile_update( $user_id, $old_user_data ) {
    		$uc = get_users(array('meta_key' => $meta_key, 'meta_value' => $meta_value));
  • The topic ‘Validate user profile when update?’ is closed to new replies.