Forums

Dont Send Empty fields in Email

rajaMansoor 24 Oct, 2015
Hi All,

I have created a Multipage form in chronoform 5 everything is working perfectly fine it is sending me Email with attachments also.

Main issue is there are some fields which are not Mandatory such as Landline Number which i m using as {Landline} in field.

So what we need is that if the field {Landline} is empty than it should not be sent in Email not even the Title* of Landine

Example Email messgage

Name : {FirstName}
Email : {EmailAddress}
Cell number : {Mobile}
Landline number : {Landline}

The text written on Left side and bold are Titles* . the right side one are fields which user inputs in form.


Thank you for the support
Raja Mansoor
GreyHead 24 Oct, 2015
Answer
1 Likes
Hi Raja,

You have to manage the template contents using PHP either in the Email template itself or in a Custom Code action before the Email action. Please check this post for an example.

Bob
francosdad 17 Nov, 2015
Hello Bob, you should edit the link, somehow it got messed up.
This topic is locked and no more replies can be posted.