Filters the default From email address used when sending Groundhogg emails.
apply_filters( 'groundhogg/get_default_from_email', $from_email );
You will receive the default from email address string.
Example
add_filter( 'groundhogg/get_default_from_email', 'my_extension_dynamic_from_email' );
/**
* Use a subdomain-based from address depending on the current site.
*
* @param string $from_email
*
* @return string
*/
function my_extension_dynamic_from_email( $from_email ) {
$domain = parse_url( home_url(), PHP_URL_HOST );
return 'hello@' . $domain;
}
Was this helpful?
Let us know if this document answered your question. Thatβs the only way we can improve.
