Form on external site not redirecting | Community
Skip to main content
Level 3
August 17, 2023
Solved

Form on external site not redirecting

  • August 17, 2023
  • 3 replies
  • 3282 views

We have external developers creating a microsite for us but for some reason the Marketo forms we've created for them are not redirecting to the ungated version of the site and instead just display a thank you message, even though the form is set to redirect.

I'm guessing there's a conflict with some other code on the site they've created but is anyone able to see what it may be from this link?

Thanks

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by SanfordWhiteman

The problem is in this external JS file which includes a custom onSuccess listener that returns false:

l && u && x && L && A.then(() =>{ MktoForms2.loadForm(`https://${ L }.marketo.com`, x, u, M=>{ M.render(MktoForms2.$(G.current)), M.submittable(r), M.onSuccess(() =>(j(!0), !1)) }) })

Note it’s quite irresponsible of your developer to minify & package JS like this if they need 3rd parties to help them with their code.

3 replies

Jasbirka
Level 5
August 17, 2023

Hi @trevlarrr

 

You have to remove the below code from your page and related JS as well.

 

 

Thanks!

Jasbir

trevlarrrAuthor
Level 3
August 18, 2023

Thanks @jasbirka apparently that is it but whatever they've used to build the site, that part of code is read-only so having to find a way to edit around it.

SanfordWhiteman
Level 10
August 18, 2023

So they chose a 3rd-party site builder that doesn’t allow customization of Marketo form behaviors, only supporting on-page Thank You text? Pretty disappointing on a professional level, you have to be on top of this stuff.

 

I see the form doesn’t show at all right now because the Forms 2.0 library isn’t loading. Presumably they’re trying to handle Marketo forms themselves instead of trusting the 3rd party, which is the right move.

Level 2
August 17, 2023

Check for this solution, mentioned here with the same problem, this might help
https://nation.marketo.com/t5/product-discussions/form-not-redirecting-on-completion/m-p/185793#M133705

SanfordWhiteman
Level 10
August 17, 2023

Please try to provide something more helpful to the OP than simply restating their question.

Level 2
August 17, 2023

Sure, on reviewing the LP, I found the form itself has the setting for showing a success message on submit, you need to add the redirection on form level only.
"successTitle":"Thank you. ","successBody":"You'll now be redirected."

SanfordWhiteman
SanfordWhitemanAccepted solution
Level 10
August 17, 2023

The problem is in this external JS file which includes a custom onSuccess listener that returns false:

l && u && x && L && A.then(() =>{ MktoForms2.loadForm(`https://${ L }.marketo.com`, x, u, M=>{ M.render(MktoForms2.$(G.current)), M.submittable(r), M.onSuccess(() =>(j(!0), !1)) }) })

Note it’s quite irresponsible of your developer to minify & package JS like this if they need 3rd parties to help them with their code.