Adding registrations to your event
Individual events can be flagged as allowing registration. When this is done, users viewing the event details on your web site will be presented with an event registration form. The form allows them to enter their first and last name, e-mail address, phone number, number of people attending, and any additional comments they may have.
Registrations are collected and become manageable within LiveWhale.
- From your event’s edit screen, check the box labeled “Let visitors RSVP for this event”.
- If you want the registration to automatically close after a specific number of attendees have registered, enter the number in the field provided.
- If you want to specify additional requests to users registering for the event, use the text field provided to do so. At the time of registration, users will be given a text field with which to respond to those requests.
- Check the box, “Notify by email when RSVPs are submitted” to receive notifications.
- Click “Save”.
Your event will appear with a rsvp form below the details, and the registrant will receive a notification of the registration with a downloadable link to add to their calendar.
RSVP Notifications
When an individual registers for an event, they’ll receive an automated email confirmation. You can customize the message in that email on a per-event basis, or customize the whole template at the server level.
You can also optionally configure an email reminder which gets sent to all registrants ~24 hours before your event starts and an email follow-up to be sent ~24 hours after the event.
RSVP Waitlists
You can choose to accept RSVPs to a waitlist if your maximum number of RSVPs has been reached. The next person on the waitlist will automatically be registered (and receive a confirmation email saying “Your registration has been confirmed and you are now off the waitlist.”) in the following cases:
- You (or another editor) edit the event, increasing the number of available slots or removing the registration maximum.
- You (or another editor) cancel another reservation, opening up an available slot.
RSVP Custom Fields
When you allow events to include an RSVP a set of default form fields are included in the registration form.
The default fields include the following:
- Attendees (required)
- First name (required)
- Last name (required)
- E-mail address (required)
- Phone
- Comments
The following instructions describe how to include additional fields:
- Access the LiveWhale filesystem through SFTP
- Locate your global.config.php file. This file is found outside your webroot at /livewhale/client/
- Adjust the
$_LW->CONFIG['RSVP_FIELDS']
configuration setting to include the name, type, and requirement of the field - Custom fields can be applied to all calendars using ‘global’ or indicate the group id as shown below (ex., ‘3’) to add custom fields to a specific calendar group
- For each custom field, the associative array will have:
- Key = the system ID you’d like to use for this field, comprised of a-z and underscores. In the examples below: “color”, “word”, “letters”, “numbers”, “animal”, and “long_text”.
-
Value = an associative array with the following key/value pairs
- header: This is the label of your form field
- instruction: Include instructions if necessary by entering a brief description
- is_required: Make the field required by setting to “true” else set to “false” if optional
- type: Indicate whether this field is ‘select’,’radio’,’checkbox’, or ‘text’ input field. If not indicated, a text field will be used by default.
- options: If a ‘select’,’radio’, or ‘checkbox’ is used create an array of options for field values.
Below is an example configuration of custom RSVP form fields with selection lists, radio, checkbox options.
$_LW->CONFIG['RSVP_FIELDS']=[
'global'=>[
'color' => [
'header'=>'Color',
'instruction'=>'Enter your favorite color',
'is_required'=>true
]
],
'3'=>[
'word' => [
'header'=>'Word',
'instruction'=>'Enter your favorite word',
'is_required'=>false,
'type'=>'text'
],
'letters' => [
'header'=>'Letters',
'instruction'=>'Choose a letter',
'is_required'=>false,
'options'=>['A', 'B', 'C'],
'type'=>'select'
],
'number' => [
'header'=>'Number',
'instruction'=>'Choose a number',
'is_required'=>false,
'options'=>[2, 4, 5],
'type'=>'radio'
],
'animals' => [
'header'=>'Animals',
'instruction'=>'Choose animal(s)',
'is_required'=>false,
'options'=>['lion', 'tiger', 'bear'],
'type'=>'checkbox'
],
'long_text' => [
'header'=>'Longer text field',
'instruction'=>'You can type more here',
'is_required'=>false,
'type'=>'textarea'
]
]
];
After the configuration is saved the rsvp form will include the additional fields after the defaults.
The event editor will include a section indicating to the publishers that these fields will be included in their rsvp form. Changes to the form fields will require an administrator who has stfp access to the filesystem.
RSVP Custom Validation
You may want to add validation to some of the above custom RSVP fields. The process involves creating a function named livewhale.custom_rsvp_validation
that returns an array of error messages when your validation criteria aren’t met.
We recommend adapting the following to your needs and adding to calendar-custom.js, or another .js file in your theme:
(function($, LW) {
$('body').bind('paymentFormLoad.lw', function() { // when RSVP form loads
livewhale.custom_rsvp_validation = function() { // add custom validation
var errors = [];
// Replace the below with whatever RegExp or other validation code you want,
// and push any error messages onto the end of the errors array.
if ($("#lw_payments_field_custom_1").val() == 'Bad value') {
errors.push('Please enter another value.');
}
return errors;
};
});
}(livewhale.jQuery, livewhale));
Adding a LiveWhale Form to your RSVP
You can attach a custom form to an Event RSVP, allowing you to gather additional information besides the default fields.
- Create a form with additional form fields to append to the existing information collected in the RSVP form (Number of Attendees, First name, Last name, Email, Phone)
- Create your event.
- Under the RSVP section, use the drop-down list along side “Require RSVPs to submit additional form:” to choose your form from step 1 to append to your event.