• Would like to be able to include shortcodes in the email template for recipients. Client wants to include most recent reports posted to the site and I’ve had to enter them manually which I’m trying to avoid.

    It apparently can be done with Contact Form 7 adding this to functions.php:
    add_filter( 'wpcf7_form_elements', 'do_shortcode' );

    and

    function my_special_mail_tag( $output, $name, $html ) {
    	if ( 'myshortcode' == $name )
    		$output = do_shortcode( "[$name]" );
     
    	return $output;
    }
    add_filter( 'wpcf7_special_mail_tags', 'my_special_mail_tag', 10, 3 );

    (https://www.howtosnippets.net/wordpress/make-custom-shortcodes-work-in-contact-form-7-mail-form-templates/)

    Does EBD have a filter available to allow for this?

    Thanks for your help!

    • This topic was modified 6 years, 10 months ago by sgarcia513.
    • This topic was modified 6 years, 10 months ago by sgarcia513.
Viewing 1 replies (of 1 total)
  • Thread Starter sgarcia513

    (@sgarcia513)

    Any chance adding shortcodes to email templates is on the EBD roadmap at any point?

    Thanks!

Viewing 1 replies (of 1 total)
  • The topic ‘Enable shortcodes in Email Template’ is closed to new replies.