Hi.
is there a way to redirect the user to a "thank you" page after the message sent?
10x
Hi.
is there a way to redirect the user to a "thank you" page after the message sent?
10x
I am looking for the same thing....
I found a way to make it work -- in the contact-form-7.js file...
line 90:
if (1 == data.mailSent) {
jQuery(data.into).find('form').resetForm().clearForm();
//wpcf7ResponseOutput.addClass('wpcf7-mail-sent-ok');
window.location = "http://mysite.com/thank-you/";
Instead of having it add the thank you response output, I redirect it to my thank you page.
Definitely a hack, but does what I need it to do.
Anyone get this hack to work?
Relish1227....
Does this hack not play nicely with certain plugins?
I found this on the author's site. Haven't tried it myself, but they said it works:
http://www.grapethinking.com/wordpress-contact-form-7-plugin-landing-pag
No dice. I get the same response with grapethinkings hack as I do with relish1227's hack. It ignores the site and goes directly ajax plug-in.
If anyone gets it to work please let me know.
Thanks
Relish's "hack" seems to work fine for me.
I just upgraded to the latest version, if that makes any difference?
Question though: does the .js get overwritten with the next upgrade. Apologies if that's a noob question, I'm no coder!
Thanks Relish.
Mark,
What plugins are you using with your site. I am trying to figure out if there is some conflict going on when redirected.
Thanks
Dan
Tillisonm,
What other plugins are you running…? I still can not get this hack to work
I have these running:
akismet
all-in-one-seo-pack
contact-form-7
google-analyticator
google-sitemap-generator
tinymce-advanced
wp-super-cache
location.href=”http://www.xxx.com/thank-you-contact-form”;
also does not work for me...
I had two instances of jquery appearing. It was blocking me from changing anything in the .js file. By default it was going to the .php file.
Thanks for the help everyone.
Nope, can't get it to work - not Relish's version or from grapethinking.com. Sure wish it would!
Hi,
In the newest version of Contact Form 7 is there a way to do this? I am not the best with javascript, but it seems there should be a way to do it using "Additional Settings". Anyones know how?
Thanks,
Dan
I am also interested in this.
I tried both 'hacks' and I did not manage to get it working. It keeps showing the AJAX message even if I get rid of the line.
Any idea?
Thanks a lot
I tried cutting and pasting the hack code into the .js file at line 90 (which happened to be the bottom of the form), then uploaded it to my site. Nothing at all changed.
I'm a novice so I probably shouldn't be gambling in this area.
I'd love to return the visitors to another page with a couple of PDF's as a thank you after they submit their email.
Can you please HELP?
Much thanks!
Put this in the Additional Settings field and it will redirect you to the page when the user clicks on the submit button.
on_sent_ok: "location.replace('http://www.YOURSITE.com');"
A fall-back option is to rewrite the "Your message was sent successfully. Thanks." message to something that you would have put on your Thank You page.
The on_sent_ok worked perfectly for us!
I'm still unable to get the hacks or built in options to redirect my page. It sends and then displays the generic thank you message on the same page. How can I check if JQuery is actually running? It appears that it isn't hitting the the .JS file at all for settings.
Thanks!
Likewise, I have tried both suggested 'hack's and neither worked. It seems as if the .js isn't making a difference -- However, it seems really elegant using the 'additional settings'
Is any prefix needed prior to the:
on_sent_ok: "location.replace('http://www.YOURSITE.com');"
Hope we can resolve it -- it is a popular request.
Cheers.
You just make a thank you page, grab the URL of that page, and paste it into the “Additional Settings” box at the bottom of the Contact Form 7 settings screen like this ...
on_sent_ok: “location.replace(’http://yourdomain.com/thank-you/’);”
replace “yourdomain” with you own, of course.
Not working for me either.
I would love to use this for my Google Adwords PPC conversion tracking.
Any other ideas how to track conversions?
Cheers!
Karl
The redirect is not working for me either:
on_sent_ok: “location.replace(’http://yourdomain.com/thank-you/’);”
I am running WordPress 2.8.5.
Any other ideas? This is a requirement for my client who has an insurance site and the redirect must go to his agent page.
I am unable to find any other plugins that allow both multiple forms and this possible setting.
Any help is appreciated! Thanks so much!
KIP
I'd really appreciate some help on this issue as well. Any ideas how to get the Additional Settings field to work with a "Thank You" page?
Thanks everyone!
ajanini,
I am not sure if you are still interested in this. But I have tested it and it works perfectly.
All I did was to type the line of code instead of copy+paste since the web page rendering has curly quotes.
And of course made sure that the intended landing page exists!
HTH
S.K
not working not working :(
I tried
on_sent_ok:"location.replace(http://google.com);"
on_sent_ok:"location.replace('http://google.com');"
Using wp 2.8.5 with latest forms7
It's just a javascript action hook, so obviously doesn't work if nothing calls it. Make sure that Contact Form 7's javascript is correctly loaded.
C forms plug in lets you redirect to thank you page and is easy to use and you can easily insert the forms in a post or page. I am currently using contact form 7 and will need to redo my forms with cform so that I can track adword conversions on the thank you pages from multiple forms.
You must log in to post.