Plugin - Forms

The Forms plugin allows you to pass necessary information into a hidden field on the form and then into the CRM system, including the Strala UUID. The Strala UUID is needed to tie Touchpoint Interaction Events to Conversion Events.

Plugin Usage

The  forms plugin will automatically fire an "event" on form submission (see the events plugin). The event can be configured with the following data attributes applied to the form:

IMPORTANT: If no event is configured, the default event that will be of type  conversion
Configuration Options (custom data attirbutes)
data attribute description
data_strala-event_type The type of event to be tracked ( touchpoint or conversion)
data-strala-event_id The "id" of the event (default: "window.location.href")
data-strala-event_source ( conversion only) The "source" of the event (default: "form")
data-strala-event ( conversion only) The "event" for the event (default: "form submit")

Firing an event on form submit can be disabled by applying the data attribute  data-strala-event-disable

Basic Implementation

Once a form is created, the following code needs to be embedded on that page within the form tag.

<form ... data-strala-form>
  <input type="hidden" name="strala_uuid" value="" />
  ...
</form>

IMPORTANT: Note that each implementation has a hidden field of name  strala_uuid. The form plugin will fail if this field is not included in the form

The  data-strala-form portion of the code is a flag to indicate the page is using the Form plugin.

The  <input ... /> portion of the code creates a hidden field named strala_uuid, which is a necessary placeholder to store the Strala UUID for downstream processing.

Example Implementations:
<!-- bare minimum configuration: fires a "conversion" event (default) on submit --> 
<form ... data-strala-form>   
	<input type="hidden" name="strala_uuid" value="" /> 
	... 
</form>  

<!-- bare minimum configuration: will not fire an event on submit --> 
<form ... data-strala-form data-strala-event-disable>   
	<input type="hidden" name="strala_uuid" value="" />   
	... 
</form>  

<!-- fires a "touchpoint" event on submit --> 
<form ... data-strala-form data-strala-event_type="touchpoint">   
	<input type="hidden" name="strala_uuid" value="" />   
	... 
</form>  

<!-- changes the "id" of the fired event --> 
<form ... data-strala-form data-strala-event_id="new id">   
	<input type="hidden" name="strala_uuid" value="" />   
	... 
</form>  

<!-- changes the "event" of the fired event (conversion only) --> 
<form ... data-strala-form data-strala-event="new event">   
	<input type="hidden" name="strala_uuid" value="" />   
	... 
</form>  

<!-- changes the "event source" of the fired event (conversion only) --> 
<form ... data-strala-form data-strala-event_source="new source">   
	<input type="hidden" name="strala_uuid" value="" />   
	... 
</form><br>
	
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.