Don't miss out Virtual Happy Hour this Friday (April 26).

Try our conversational search powered by Generative AI!

Problems with multiple e-mail addresses in xforms



I need to add multiple e-mail addresses in xforms for a button. I add the addresses separated by semi-colons in the field "Send e-mail to this address". When clicking save i get the following error message:

";" is not a valid e-mail address.

In the editors manual for CMS 7 it says:

In Send e-mail to this address, type the e-mail address that a message is to be sent to when a visitor posts a form.
Send e-mails to several recipients by entering the e-mail addresses separated by semi-colons, for example,;
Does anyone know what to do with this? I tested it on an alloy-tech sample site as well as my companys site, and got the same error message.
Aug 15, 2013 16:02


Thanks for the report. This is a bug that was introduced when standardizing our email validation across products. We simply missed that it was possible to enter multiple adresses. I have created the following bug for this:

Bug #104410: Not possible to enter multiple email adresses for xform submit buttons
You can do a temporary patch by changing one row in the XFormEdit.aspx file in the system files. Find the row where the emailRegex is defined and change it to this instead:
emailRegex = <%="/^([a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?\\.)+[a-zA-Z0-9](?:[a-zA-Z0-9-]*[a-zA-Z0-9])?[;]?)+$/" %>;
Aug 15, 2013 18:45

Hi Linus,

There is also a strange thing for xform validation. When I choose data type to email and just click the checkbox for input required field.

When I click the submit button and do not enter anything in textbox, the errormessage 'email is not valid' always appears.

I wonder if I can find a solution to

1. When I input nothing,then required error appears.

2. When I input invalid email. then invalid email error appears.

By the way,I just use xform in my MVC project.

Aug 16, 2013 3:22

Thanks Linus!

Your temporary solution works.

Aug 16, 2013 9:11

Martin: I fixed the incorrect validation message that appears when using a required email field in MVC but unfortunately there is no easy work around so you will have to live with it until the next release.

Aug 16, 2013 11:45

Thanks, Linus. We just wait for the next release.

Aug 16, 2013 11:48

Hi Linus

I did the temporary fix as suggested above but I get this message while submitting a form:

An invalid character was found in the mail header
Dec 22, 2013 18:44

@Sayeed: I do not recognize the error message so I suggest that you debug the failing mail message to see if you can find the invalid character. The perhaps it's easier to find the cause.

You could also see if you can reproduce this on a clear EPiServer 7.5 site since the original bug should be fixed in this version.

Edited, Dec 27, 2013 10:31

Hi Linus

We are using EPiServer 7.1 build 7.0.586.24. It works fine if I have ony one emai address on the xForms "send email to" field. The error only shows up when I try to add multiple email addresses seperated by ";". So this probably has to be an issue with adding multiple email addresses seperated by semicolon. 

Dec 27, 2013 14:27

Hi Sayeed, we know about the problem and thus the reference to the bug earlier in this thread. This bug should be fixed in EPiServer 7.5 so if the temporary fix above does not solve this upgrading should remove the bug.

Dec 29, 2013 10:09

Hi Sayeed,

I've got exacly the same issue as you in same EPiServer version when using MVC. I fixed that by overriding of ProcessXFormAction. My ProcessXFormAction is defined as below:

protected override bool ProcessXFormAction(System.Web.Mvc.Controller controller, EPiServer.XForms.Util.XFormPostedData post)
	var xFormData = new XFormPageHelper().GetXFormData(controller, post);
	xFormData.MailTo = post.SelectedSubmit.Receiver;
		return XFormActionHelper.DoAction(xFormData, post, true);
	catch (Exception exception)
		controller.ModelState.AddModelError("ProcessXFormAction", exception.Message);
		return false;


The only change according to orginal ProcessXFormAction is line starting with 

xFormData.MailTo = post.SelectedSubmit.Receiver;


Edited, Jan 08, 2014 23:56

Hello Linus,


Thanks for your help. We are experiencing the same issue running on EPiServer 7 Patch 3.  And EPiServer 7.1.3


Is this item solved in EPiServer 7 Patch 4?

If not:

  • Is there any other way to apply this workaround without having to touch EPiServer file XFormEdit.aspx ?
  • Is there an expectation to fix this for EPiServer 7.1 (Not 7.5)


Thank you so much.

- Wacdany.

Apr 22, 2014 6:21


I am getting the same issue even though our EPiServer assembiles are at version 8.9.

Has this still not been fixed in 8.9?



Oct 26, 2015 7:59

Just tested this in a 9.2 installation - still not fixed. Tried both semi-colon and colon (as implied in this bug thread).

However, the new Forms module (the much needed replacement for XForms) should be released within weeks. 

Nov 06, 2015 14:27

Any news if this is fixed in latest?

Jan 26, 2016 11:44


Jan 28, 2016 23:44

Well, multiple email recipients is fixed in the new Episerver.Forms. (tested with

Using a comma-separated list of emails will result in multiple recipients. 

(side note: turns out, when using semi-colon, it's treated as a display name/email pair, so it will be generated as:

TO: "" <> and your mail client will probably get confused. 

Jan 29, 2016 12:14
This thread is locked and should be used for reference only. Please use the Episerver CMS 7 and earlier versions forum to open new discussions.
* You are NOT allowed to include any hyperlinks in the post because your account hasn't associated to your company. User profile should be updated.