Automate Submission Event Tracking

Created on 19 January 2024, 6 months ago
Updated 4 April 2024, 3 months ago

Problem/Motivation

Currently browser support the tracking of form submissions automatically, which is then used inside Google Analytics, Matomo and other analytics tools to be able to capture the amount of form submissions.

This removes the need to setup additional modules and perform site specific development to capture all submissions (regular, ajax, confirm message, confirm page, ....). It is therefore very interesting to explore to cut development costs in delivering this information.

Steps to reproduce

  • Setup empty (GTM) container
  • Add a "Form submission" trigger that fires on all forms
  • Create a simple webform
  • Don't use AJAX
  • Submit the form (You get a formSubmit event in GTM)
  • Change the form to AJAX submission
  • Submit the form (You don't get a formSubmit event in GTM)

Proposed resolution

Adjust webform to allow it to support the native browser submit feature. This might involve making adjustments to current onsubmit JS events capturing.

✨ Feature request
Status

Closed: won't fix

Version

6.2

Component

Code

Created by

πŸ‡§πŸ‡ͺBelgium hoebekewim

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @hoebekewim
  • πŸ‡ΊπŸ‡ΈUnited States cilefen

    I don’t understand what this feature request is asking to implement. That could be my own ignorance. Perhaps the issue summary would be improved by adding some links to fundamental documentation.

  • πŸ‡§πŸ‡ͺBelgium kaduk
  • πŸ‡§πŸ‡ͺBelgium kaduk

    Updated steps to reproduce.

    The problem is that when you have a webform that is not using AJAX and you setup a trigger that fires on form submits, you get the event entry in GTM (for example).
    When you change the webform to use AJAX and submit again, the GTM trigger is not fired anymore.

    Could we have a way so that disregarding of the webform submit settings/AJAX settings, that we can track the form submit action by default?

  • Status changed to Closed: won't fix 3 months ago
  • πŸ‡ΊπŸ‡ΈUnited States jrockowitz Brooklyn, NY

    Any new features should be handled in a dedicated contributed module.

Production build 0.69.0 2024