Mida allows you to send events by using Javascript when specific actions take place on your website. An event is a data point representing an interaction between a user and your website.
With Javascript, you're able to set up your own criteria to determine what kind of action results in an event being sent to Mida.
Below is the use case for the event:
Send an event to Mida to let you know when a user loads a specific page variant during an AB test.
window.mdq = window.mdq || []; window.mdq.push(["track", "ab_testing", { "userID": 123, "transactionID": 345, "custom": "Can be anything" }]);Send an event to Mida when users click on a specific button on your website.
window.mdq = window.mdq || []; window.mdq.push(["track", "subscribe"]);
Note: You can provide the name of the event as the first argument. Optionally you can add data to your event by providing an object as a second argument.
Alternatively, you can also add it as a HTML attributes mida-event:
<button class="btn" mida-event="click-cta">Create a free account</button>
Whenever, someone clicked on the CTA button it will trigger an event with the name "click-cta".
