Hello,
I’d like to integrate directly a Java Script in a field in a Marketo form.
The JS will be provided by a 3rd party service. The goal is to help the prospect filling the form to identify his company.
I know it’s feasible but I don’t know how to do it, I have just tested with a copy-paste in a rich text field and it failed. Does it require developer skills?
Do you use JS in a field and does it work well? Any issue of slow loading?
I have found only one post about this kind of topic.
https://nation.marketo.com/t5/Product-Discussions/Embed-JS-directly-in-a-form/m-p/34559
Thank in advance.
Vincent
Solved! Go to Solution.
I explained how to do this here: HOWTO: Add Forms 2.0 JS behaviors inside a Rich Text Area
There is no performance impact vs. using a standalone <script> tag outside of the form (i.e. after the form embed code). However, be very wary of bundling code inside the form this way unless you are absolutely sure the code works on its own. Putting it in a Rich Text Area makes it tons harder to debug. Only use the RTA in the situation where you cannot add code beyond the form embed (as in, someone is already using your form embed on another site and won't plug in an additional <script>).
I explained how to do this here: HOWTO: Add Forms 2.0 JS behaviors inside a Rich Text Area
There is no performance impact vs. using a standalone <script> tag outside of the form (i.e. after the form embed code). However, be very wary of bundling code inside the form this way unless you are absolutely sure the code works on its own. Putting it in a Rich Text Area makes it tons harder to debug. Only use the RTA in the situation where you cannot add code beyond the form embed (as in, someone is already using your form embed on another site and won't plug in an additional <script>).