To send HTML private message, you must add :
[
edited – Please use the ‘code’ button when you post code. Please note that removing that filter creates a major security risk.
It means user input WILL NOT BE SANITIZED.
So some very bad things can happen to your database.
] remove_filter( 'messages_message_content_before_save', 'wp_filter_kses', 1);
SELECT wp_bp_activity.user_id AS ID FROM wp_bp_activity WHERE wp_bp_activity.type = 'last_activity' AND wp_bp_activity.user_id IN(SELECT user_id FROM wp_bp_xprofile_data WHERE value LIKE '%cancer%' OR value LIKE '%neoplasms%' ) ORDER BY date_recorded DESC LIMIT 0 , 20