Hi all,
I've created a guided landing page and have set to redirect to an external page after the form submission.
I'd like to pass the value of the FirstName field and then to render it on a Wordpress page with the message saying something like.
"Thank you, {FirstName} for getting in touch..."
Does anyone know if this is possible? I tried this tutorial here but it I couldn't get the value to append to the URL:
https://blog.teknkl.com/append-fields-to-thank-you-url/
Any help would be much appreciated!
Solved! Go to Solution.
Nothing wrong with the code in that post, it’s well tested.
What’s the URL of the page you tried this on?
Hi @SanfordWhiteman Thank for your reply!
The code is good so I know my implementation/setup is causing the issue. 😅
This is my landing page here: https://you.oxfam.org.au/Test-first-name-variable.html
and for testing I've set up a redirect to https://www.oxfam.org.au/marketo-thank-you/
Your solution makes perfect sense but for the life of me I can't figure out what i'm missing to pass the values to the URL parameter.
Sorry, i'm a bit of a newb with these marketo dynamic stuff.
Any help would be much appreciated 😃
Thanks @SanfordWhiteman for looking into this. Really, appreciate all the help so far 😃
I moved the script just before the closing </body> tag but unfortunately, I can still can't get it to pass the values into the URL.
I added a console log to write after the onSuccess function to see the resulting URL string of the Thank you page.
Not too sure what i'm missing 😅
That’s just checking the value of the Thank You URL before it’s modified, i.e. the thankYouURL
argument.
Naturally, it won’t have any additional query params added. In fact, the original arg is never modified.
Your problem is that you’re adding anotheronSuccess
listener in a GTM-injected script:
You need to remove the eventCallback
from that code because it’s taking precedence over the inline onSuccess
.
Hey @SanfordWhiteman that makes sense.
I'll look to remove the eventCallback from the GTM inject script.
Thanks again for your help. Much appreciated 😃
Update: It worked!