Forum Replies Created

Viewing 2 replies - 1 through 2 (of 2 total)
  • Plus one for this feature. A simple text description that would allow some basic html formatting would be fine – no need for a wysiwyg editor. Description should be above the gallery and below the title, so I can read what the photos are about, then see the photos.

    Thread Starter jbellle74

    (@jbellle74)

    I added the following code to my functions.php file and I am now receiving emails from the frontend form. But I receive an email whenever a new event is added to the database – frontend or backend. I only want to receive the notifications when the frontend form is submitted.

    add_action(’eme_insert_event_action’,’eme_mail_event’);
    function eme_mail_event ($event) {
    $contact = eme_get_contact ($event);
    $contact_email = “[email protected]”;
    $subject_format=”An New Event Has Been Submitted ‘ #_EVENTNAME ‘”;
    $body_format=”An New Event Has Been Submitted <br /><br /> #_EVENTNAME in #_TOWN, #_STATE <br /> #_EVENTDETAILS <br /><br />
    #_STARTDATE at #_STARTTIME to #_ENDDATE at #_ENDTIME <br /><br /> Contact: #_CONTACTEMAIL<br /> <br /> Please log into the admin to approve the event.”;

    $subject=eme_replace_placeholders($subject_format, $event, “text”);
    $body=eme_replace_placeholders($body_format, $event, “text”);
    eme_send_mail($subject,$body,$contact_email);
    }

Viewing 2 replies - 1 through 2 (of 2 total)