Using field alias value in text

Load this form with a prefill of https://app-test.tfaforms.net/4906505?tfa_1=Tony%20Stark 

Hello ,

Welcome to this form. I hope you find it helpful!

Have a great day!
    FABANNER

Javascript used
**Custom code used - Please note this is provided as a courtesy and falls outside our support scope. ***

First add TEXT element (not input) and within the HTML option place a SPAN element wherever you want the prefilled value from the hidden field to go. Give this SPAN element an id of 'name'

dsf

Now you simply add the below code snippet to the custom code section. Remember to change the tfa_1 value to the tfa alias of the field you are prefilling on your form that can be set to hidden. 


<script>
window.addEventListener("load", () => {
let name = document.getElementById('tfa_1').value;
document.getElementById('name').innerHTML = name;
  });
</script>