I am wondering if there is a way to override the Submit button's text value(it is reading as 'Submit' and needs to be updated to 'Get Started'). Currently the form is being referenced across multiple landing pages so I cannot change the value in the form itself but need to override it in the current landing page. Please advise, thanks.
There might be a more efficient way, but this should work:
<script>
MktoForms2.whenRendered(function (form){
form.getFormElem()
.find('button.mktoButton')
.html('BUTTON NAME');
});
</script>
In this particular case, unless the label is also going to change when VRs fire, it's okay to use whenReady rather than whenRendered (as the button will always be in the DOM on ready).
Hi,
I tried this with the following code:
MktoForms2.whenReady(function (form){
$(".mktoButton"). html("Get Started");
});
Hope it will help.
Thanks
This code isn't correct. You only want children of the current form element, like in JD's example, not the entire document.