• Is there a way to easily route a user to a webpage upon submission of a contact form? For example, if I wanted to offer a download or a special deal on a page, but wanted to capture their email address and name first, then send them to that destination page.

Viewing 5 replies - 1 through 5 (of 5 total)
  • As what it provides is basic mail form, I don’t think Contact Form 7 is suitable for your idea.

    Why not sending email reply with the URL manually to contacting users?

    Or, if you know javascript, you could achieve it by using new on_sent_ok hook.

    https://ideasilo.wordpress.com/2009/05/31/contact-form-7-1-10/

    Could you post an example of how this would work?

    This does not work:

    on_sent_ok: "location.href=”https://www.domain.com/next-page”;"

    Any help would be great!

    Thanks,

    Dan

    Could you post an example of how this would work?

    This does not work:

    on_sent_ok: "location.href=”https://www.domain.com/next-page”;"

    Any help would be great!

    Thanks,

    Dan

    Philip Jones

    (@philipmartinjones)

    I suspect you are having problems because of the extra speech marks. Change the inner ” to ‘ like this:

    on_sent_ok: “window.location=’https://www.domain.com/nextpage’;”

    I’m having a similar problem. I need to link to a different page after submit, and everything I read is telling me I’m doing it correctly. But nothing is working. Here is my code:

    on_sent_ok: “location.replace(’https://www.nightmareon13th.com/coupon.html’);”

    I must be missing something, does anyone have any ideas?

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘[Plugin: Contact Form 7] route user to webpage upon submission of form’ is closed to new replies.