Customize Email Header Branding Per Show
On a multi-show installation every show sends through the same email wrapper, so without intervention all three of your podcasts arrive looking identical. benecaster_email_wrapper_args receives the show ID, which makes per-show branding a lookup rather than a template override.
Prefer this filter over copying base.php into your theme. An overridden template is frozen at the moment you copied it — later fixes to the wrapper never reach your site — whereas a filter keeps working across updates.
The is_admin_email flag is worth respecting. Admin emails go to you, not to subscribers, and they omit the unsubscribe link. Applying show branding to them is usually noise.
Code
<?php
add_filter(
'benecaster_email_wrapper_args',
function ( array $args, string $email_type, int $show_id ): array {
// Admin emails keep the default styling.
if ( ! empty( $args['is_admin_email'] ) ) {
return $args;
}
$branding = [
12 => [ 'accent' => '#1a5f7a', 'logo' => 'https://example.com/logo-show-a.png' ],
34 => [ 'accent' => '#7a1a2f', 'logo' => 'https://example.com/logo-show-b.png' ],
];
if ( ! isset( $branding[ $show_id ] ) ) {
return $args;
}
$args['accent_color'] = $branding[ $show_id ]['accent'];
$args['logo_url'] = $branding[ $show_id ]['logo'];
$args['footer_text'] = $args['show_name'] . ' — thanks for listening.';
return $args;
},
10,
3
);