Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • data - Required. The event data in JSON format. For example:
    {
       "e":"Custom event",
       "metaData": {
          "price": 5,
          "name": "book"
       }
    }

    e - custom event name
    metaData - a list of parameters and their values

  • eventCallback - Optional. Function to be executed after the event is sent.

...

In order to send a click event on the DOWNLOAD button, add a call to the sendEvent function to the button onclick event as seen below:

 
Info
iconfalse

<input type="button" value="DOWNLOAD" onclick="openDownloadForm();

CardioLogAgent.API.sendEvent({e: 'Button Click', metaData: {name: 'DOWNLOAD NOW'}}, function () {console.log('event sent successfully');});" />

...