Skip to main content
All CollectionsTroubleshooting and FAQsFrequently Asked QuestionsContact Form Module
How to Send a Copy to the Sender Using the Contact Form Module
How to Send a Copy to the Sender Using the Contact Form Module

Learn how to customize the Contact Form module to send a copy of the email to sender.

Updated over a week ago

The Contact Form Module allows website visitors to easily get in touch with you.

Sometimes, it's beneficial for both you and the sender to receive a copy of the submitted form.

This guide will walk you through the steps to configure your contact form to automatically send a copy of the submission to the sender.

  1. If you don't use a Child theme, install and activate one

  2. Using an FTP connection, hosting File Manager app, or the Advanced File Manager plugin, navigate to your child theme folder and create a new folder name module

  3. In the module folder, create a new PHP file called ContactForm.php

  4. Copy/paste the code from this page

  5. Edit the functions.php file inside your child theme, and after the existing code, add this PHP code:

    /*================================================
    #Load custom Contact Form Module
    ================================================*/
    function divi_custom_contact_form() {
    get_template_part( '/module/ContactForm' );
    $dcfm = new Custom_ET_Builder_Module_Contact_Form();
    remove_shortcode( 'et_pb_contact_form' );
    add_shortcode( 'et_pb_contact_form', array( $dcfm, '_render' ) );
    }
    add_action( 'et_builder_ready', 'divi_custom_contact_form' );

    function divi_custom_contact_form_class( $classlist ) {
    // Contact Form Module 'classname' overwrite.
    $classlist['et_pb_contact_form'] = array( 'classname' => 'custom_ET_Builder_Module_Contact_Form',);
    return $classlist;
    }

    add_filter( 'et_module_classes', 'divi_custom_contact_form_class' );
Did this answer your question?