Changed /user_details

to /user_data
extractElement and extractValue work across new lines

added s modifier so that the regex will match across line breaks
Show error page on error
Replace line breaks in description with <br />

This allows you to have line breaks in your description
Return empty array if no exclusion emails have been set

This stops null being included as an excluded email address with the
first participant signs up.
Methods for sending out emails

sendEmail() takes the relevant info and sends an email using PHP’s
mail() function. createEmailContent() takes a $content_ref (which is
linked to a template email in the data file) and an array of
$fill_values. The key to each $fill_values will be replaced in the
template with its corresponding value.
Format date in PHP script

rather than in the HTML page, since the formatted date will also be
used in the email, so it’s better just to compute it once.
Break loop early when possible

Once the correct slot has been identified, break out of the two foreach
loops
Send email on successful sign up

Once the data has been written out and there are no issues, send the
participant a confirmation email. Also, if this is a multi-person
experiment and the slot is now full, send emails to the other people in
the slot to let them know that the slot has been filled.