What about filtering the_content
?
function se365701_require_email ( $content ) {
if ( is_page( 'require_email' ) ) && !isset( htmlspecialchars( $_COOKIE['submitted_email']) ) {
return $form; // your MailChimp Form Code
} else{
return $content;
}
add_filter( 'the_content', 'se365701_require_email' );
Note that your form provide itself may have a cookie or you may need to set it when the form is filled out. You could also perhaps use $_POST[]
or $_GET
instead. You just need some way of knowing if the form was submitted.