/
Improvements for FORM.SUBMITTED e-mail (for Admin)
Improvements for FORM.SUBMITTED e-mail (for Admin)
Right now a universal e-mail is sent out to Website Administrator in case if a contact form is submitted. This e-mail is totally useless because:
- it doesn't contain form name, that was submitted (for cases, when there are multiple forms on website)
- form data (forces administrator to open Admin Console each time to see details)
Adding following code to the end of e-mail body should display all entered fields by inspecting actual submitted form configuration:
<br> <br> <inp2:m_DefineElement name="ro_form_field_text"><inp2:SubmissionTag tag="Field" field="$field"/></inp2:m_DefineElement> <inp2:m_DefineElement name="form_field_password"> </inp2:m_DefineElement> <inp2:m_DefineElement name="ro_form_field_select"><inp2:SubmissionTag tag="Field" field="$field"/></inp2:m_DefineElement> <inp2:m_DefineElement name="ro_form_field_checkbox"><inp2:SubmissionTag tag="Field" field="$field"/></inp2:m_DefineElement> <inp2:m_DefineElement name="ro_form_field_textarea"><br><inp2:SubmissionTag tag="Field" field="$field"/></inp2:m_DefineElement> <inp2:m_DefineElement name="ro_form_field_radio"><inp2:SubmissionTag tag="Field" field="$field"/></inp2:m_DefineElement> <inp2:m_DefineElement name="ro_form_field_upload"><inp2:SubmissionTag tag="Field" field="$field"/></inp2:m_DefineElement> <inp2:m_DefineElement name="ro_form_field" prefix="formsubs"> <strong><inp2:Field field="Prompt" as_label="1"/></strong>: <inp2:ConfigFormElement field="Value" blocks_prefix="ro_form_field_" element_type_field="ElementType" value_list_field="ValueList" /><br/> </inp2:m_DefineElement> <inp2:formflds_PrintList render_as="ro_form_field" SourcePrefix="formsubs" per_page="-1"/>
Adding <inp2:form_Field name="Title"/>
somewhere in e-mail subject can display actual form name, that was submitted.