I have put the embed code on a page:
https://hatch130.github.io/marketo-sandbox/
The page contains only this source code:
<html>
<body>
<h1>Marketo form test</h1>
<script src="//app-sj04.marketo.com/js/forms2/js/forms2.min.js"></script> <script>MktoForms2.loadForm("//app-sj04.marketo.com", "541-JCA-443", 539);</script>
</body>
</html>
I am expecting to see a form, but I'm seeing a blank page with no error. Any guidance much appreciated, thanks!
Solved! Go to Solution.
Also, you don't have the <form>!
Fix that, fix the overall page, it'll work.
Though you should also read this: Make your form embeds happier and more productive by loading from your LP domain (not //app-somethin...
That's not a valid HTML page. HTML must also have a non-empty <title> and a DOCTYPE at minimum.
Also, please always highlight code when pasting it into a Community post:
Also, you don't have the <form>!
Fix that, fix the overall page, it'll work.
Though you should also read this: Make your form embeds happier and more productive by loading from your LP domain (not //app-somethin...
Thanks Sanford, I was missing the form tag! This works (it's not valid HTML as you mentioned, but it works anyway):
<html>
<body>
<h1>Marketo form test</h1>
<form id="mktoForm_539"></form>
<script src="//app-sj04.marketo.com/js/forms2/js/forms2.min.js"></script> <script>MktoForms2.loadForm("//app-sj04.marketo.com", "541-JCA-443", 539);</script>
</body>
</html>
This is solved!
You need a standard DOCTYPE and valid <head>, though, or the page will break on some browsers. Can't rely on markup being added implicitly.