other shortcodes in Contact form 7 MAILS

How to use other shortcodes inside Contact form 7- forms? indeed explains how to use other shortcodes inside Contact Form 7 forms. But that doesn’t make them usable in the mails that Contact Form 7 sends on submission of the form. How do I make them work there too?

Related posts

Leave a Reply

1 comment

  1. WPCF7 incorporates more filters than used in the answer you already found.

    Analogously to that, the wpcf7_posted_data filter should do what you are looking for:

    function wpse73667_wpcf7_posted_data( $posted_data )
    {
        $posted_data = do_shortcode( $posted_data );
        return $posted_data;
    }
    add_filter( 'wpcf7_posted_data', 'wpse73667_wpcf7_posted_data' );
    

    Note that this is an educated guess and untested.

    You can find all the filters available by searching the %plugins_directory%/contact-form-7/includes/classes.php file for the term apply_filters.