From 03df1ac78cac923d33b20cd281e25f05c0d63f34 Mon Sep 17 00:00:00 2001 From: Ned Zimmerman Date: Mon, 19 Mar 2018 11:45:36 -0400 Subject: [PATCH] Hook up new email to contact form. --- inc/helpers/namespace.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/inc/helpers/namespace.php b/inc/helpers/namespace.php index 5c8631b..f74abe0 100644 --- a/inc/helpers/namespace.php +++ b/inc/helpers/namespace.php @@ -244,6 +244,7 @@ function handle_contact_form_submission() { return false; // Security check failed. } if ( isset( $_POST['submitted'] ) ) { + $contact_email = get_option( 'pb_network_contact_email', get_option( 'admin_email' ) ); $output = []; $name = ( isset( $_POST['visitor_name'] ) ) ? $_POST['visitor_name'] : ''; $email = ( isset( $_POST['visitor_email'] ) ) ? $_POST['visitor_email'] : ''; @@ -277,7 +278,7 @@ function handle_contact_form_submission() { $output['field'] = 'message'; } else { $sent = wp_mail( - get_option( 'admin_email' ), + $contact_email, sprintf( __( 'Contact Form Submission from %s', 'pressbooks-aldine' ), $name ), sprintf( "From: %1\$s <%2\$s>\nInstitution: %3\$s\n\n%4\$s",