I found the function that I needed to change in order to customize the admin email, my problem is that it doesn’t seem to let me use the custom_functions file to override that function. The name of the function is espresso_prepare_admin_email. Is there a difference between the types of functions that you can override in Event Espresso? I was able to successfully change the espresso_ical_prepare_by_meta no problem using the custom_functions technique. For now I will just add the change to the core code, and I know that you guys are probably changing alot of how this works in v4. Just wondering why it might be that I cant safely override this particular function. (I get a duplicate function declaration error).
They are different functions, in that espresso_ical_prepare_by_meta is a “pluggable” function meaning that it can be over ruled as it has a wrapper that says if (!function_exists(‘espresso_ical_prepare_by_meta’)) {
espresso_prepare_admin_email does not have this wrapper and as such cannot be over ruled.
I can request the function to be made pluggable in future updates but cannot say if or when this would happen.
Makes sense. I would definitely like this to be pluggable some day as some clients request that their admin emails be as clean and simplified as possible, so there are some bits of information that are used but not important to them in the notifications if you get what I’m saying. For now I’ll just note the change to the core file and keep an eye out. Thanks!
Viewing 2 reply threads
The support post ‘Overriding Admin Email Function’ is closed to new replies.
Have a question about this support post? Create a new support post in our support forums and include a link to this existing support post so we can help you.
Support forum for Event Espresso 3 and Event Espresso 4.