Forums

[Plugin: Contact Form 7] route user to webpage upon submission of form (6 posts)

  1. jerryh0707
    Member
    Posted 2 years ago #

    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.

  2. Takayuki Miyoshi
    Member
    Posted 2 years ago #

    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.

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

  3. djones101
    Member
    Posted 2 years ago #

    Could you post an example of how this would work?

    This does not work:

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

    Any help would be great!

    Thanks,

    Dan

  4. djones101
    Member
    Posted 2 years ago #

    Could you post an example of how this would work?

    This does not work:

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

    Any help would be great!

    Thanks,

    Dan

  5. Philip Jones
    Member
    Posted 2 years ago #

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

    on_sent_ok: "window.location='http://www.domain.com/nextpage';"

  6. kfrost1196
    Member
    Posted 2 years ago #

    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(’http://www.nightmareon13th.com/coupon.html’);”

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

Topic Closed

This topic has been closed to new replies.

About this Topic