I am not really familiar with php, but if I created a custom plugin and activate it, would this override the core code or replace it?
WP is loaded with “hooks” which can be either “filters” or “actions”. This is what allows WordPress to be customized, and it is the premise upon which all plugins are built.
A filter hook allows you to change a value. There’s a value that WP generates, and then the hook is there to allow you an opportunity to change that before it gets used.
In this particular case, the ‘wpmem_email_headers’ filter hook allows you to change the email headers that are passed to wp_mail() when WP-Members generates an email. In the example code, it’s just changing the content type so that it is an html email.
Also, are there any risks associated with adding this php filter via a custom plugin? I.e. would it affect other emailing/notification plugins or operations I have set up.
As I mentioned in the original answer – ‘wpmem_email_headers’ only affects emails generated by WP-Members.