Can someone sort this out for me? It's a lightbox style Mkto Form which needed to be showing on my landing page. But somehow after I embedded piece of code as what Marketo instructed on the Developers page, it is still not working:
<script src="//app-ab03.marketo.com/js/forms2/js/forms2.min.js"></script>
<form id="mktoForm_1814"></form>
<script>MktoForms2.loadForm("//app-ab03.marketo.com", "463-EQS-987", 1814, function (form)
if (location.href.indexOf("lightboxForm=true") != -1) {
MktoForms2.lightbox(form).show();
});</script>
Is there anything wrong with the code? Is there something else I need to add onto this piece? Appreciate it if someone could help!
Solved! Go to Solution.
Your code has a syntax error. Always look in your browser's console first.
<script>
MktoForms2.loadForm("//app-ab03.marketo.com", "463-EQS-987", 1814, function (form){
if (location.href.indexOf("lightboxForm=true") != -1) {
MktoForms2.lightbox(form).show();
}
});
</script>
Your code has a syntax error. Always look in your browser's console first.
<script>
MktoForms2.loadForm("//app-ab03.marketo.com", "463-EQS-987", 1814, function (form){
if (location.href.indexOf("lightboxForm=true") != -1) {
MktoForms2.lightbox(form).show();
}
});
</script>
Thank you Sanford! Appreciate it.