Quantcast
Channel: Developer to developer
Viewing all articles
Browse latest Browse all 9076

Adding data tags to form elements

$
0
0

Hi

I want to add some more data about the form element so I can use that in my javascript for tracking, etc.

For example, I have sigle or multi choice element on my form. When it renders,  it looks like below:

<div class="Form__Element FormChoice" data-f-element-name="__field_336" data-f-type="choice" id="c44732a8-109b-4f51-b944-d5a56f144a0c" data-enriched="true">
<span class="Form__Element__Caption">Multiple or single choice</span>

So I have some data about it, but I don't have the element name anywhere to use. 

I like to have somehting like this:

<div data-name="MyFormName" class="Form__Element FormChoice" ...>

 

Is there any way to do it?


Viewing all articles
Browse latest Browse all 9076

Trending Articles