Support » Plugin: Redirection for Contact Form 7 » Request for Multiple External ReDirects

  • Resolved Alan Nusbaum

    (@alan-nusbaum)


    First off, thanks very much for having created this easy to use plugin. It works as designed. Can you in an upcoming version (soon) enable MULTIPLE redirects.

    USE CASES
    When someone completes a form, not only do I want them redirected to a Thanks page, but I also frequently want to serve them up MULTIPLE PDF’s of software products we implement.
    I tried adding a <CR> after the first external reference but the <CR> saved the changes instead of adding a Line Fee.
    Is there a work around you can suggest?
    Please reply to Alan@connectis.ca or alannusbaum@hotmail.com
    Thanks in advance

Viewing 15 replies - 1 through 15 (of 27 total)
  • Plugin Author yuvalsabar

    (@yuvalsabar)

    Hi Alan,

    In the next version we will add an option to add a script before redirection, so if you’ll add something like this: window.location.href = 'path/file.pdf'; you’ll get your way, but what I think will work best for you is to add the same code, only in the page that to user is redirected to, and you can do it right now of course, because that right now related to the plugin.

    • This reply was modified 2 years, 2 months ago by yuvalsabar.
    • This reply was modified 2 years, 2 months ago by yuvalsabar.
    • This reply was modified 2 years, 2 months ago by yuvalsabar.
    Plugin Author yuvalsabar

    (@yuvalsabar)

    Yuval, when I select a redirect page to THANKS and add script to the external box

    window.location.href = ‘http://www.connectis.ca/v/babytel/d/babytel-t38-sip-trunking-product-sheet.pdf&#8217;;window.location.href = ‘http://www.connectis.ca/v/babytel/d/cryptagent-brochure.pdf&#8217;;

    I can’t save the Contact7 form and get the error “You Must Enter A Valid URL”
    The intention was to produce 3 tabs, Thanks + 2 more PDF datasheets.
    What should I do.
    Todah Rabah – Shanah Tovah

    dharani

    (@dharanivadivelu)

    Hi @alan-nusbaum
    Do you able to redirect to atleast one pdf uploaded in WordPress(wp-content) using the external box.
    I need to redirect my page to the location where I uploaded my pdf after my form submit.
    help me please.
    Thanks in advance.

    Plugin Author yuvalsabar

    (@yuvalsabar)

    @alan-nusbaum, like I said, you can do that easily by adding that script in the page that the user is redirected to. It’s not related to the Contact Form 7 forms, but to the thank you page. Nevertheless, you should know some browsers block script-triggered popup windows\tabs by default, so unless you allow it, it will prompt a warning.

    • This reply was modified 2 years, 2 months ago by yuvalsabar.

    Yuval this isn’t a solution for me as the thankyou page is often used commonly by several other forms I use and I don’t want to pop up a tab with a PDF that has nothing to do with the current form. I expect I’ll have to wait and hope that you’ll produce something in your plugin that elegantly enables MULTIPLE External files to be defined.

    thank you

    Plugin Author yuvalsabar

    (@yuvalsabar)

    Hi @alan-nusbaum,

    Just updated the plugin, now, in version 1.2, you can add multiple redirects, including files of course.

    Please be kind and rate us 🙂

    Hi Yuval, I’ve upgraded the plugin and can now send a total of 2 PDF’s, but it’s still not working as expected. I’d like to send you a screenshot to further explain, but this blog doesn’t provide the facility. My email is alan@connectis.ca if you could send me yours, I’ll send you more details along with a screenshot so you’ll more easily understand my use case. Thanks in advance

    tardwe

    (@tardwe)

    Hi Alan (@alan-nusbaum). Did you solve the issue? I’m also trying to solve this.

    Plugin Author yuvalsabar

    (@yuvalsabar)

    Hi @tardwe,

    That can be done by adding a simple script to the textarea at the bottom of Redirect Settings tab:

    window.open('YOUR URL OR FILE', '_blank');

    Add two lines of the same – and two tabs will be opened, etc.

    Ah. Thanks @yuvalsabar. Unfortunately I misread what Alan wanted to solve. My issue is that I would like to open different thank you pages based on the selected value of a radio button section in the form.

    Plugin Author yuvalsabar

    (@yuvalsabar)

    Hi @tardwe,

    It’s also possible to use the script textarea for that – by using the event object, check the select value and redirect accordingly.

    There’s an example of a tested and working code:

    The select field:
    [select your_redirect_page "Home" "About"]

    JavaScript Code

    inputs = event.detail.inputs;
    inputs.forEach( function(el) {
        if ( el.name == 'your_redirect_page' ) {
        	if ( el.value == 'Home' ) {
        		location.href = 'http://yoursite.com/';
        	} else if ( el.value == 'About' ) {
        		location.href = 'http://yoursite.com/about/';
        	}
        }
    });

    Notice all other inputs in the plugin should remain unfilled.

    We’ve added this to the To-Do list for the next version of the plugin, so you should expect a build in support in a month or so 😉

    • This reply was modified 1 year, 12 months ago by yuvalsabar.

    Hi again @yuvalsabar,

    Sweet. Thank you so much. And great that you are adding this as a feature for next version as well 🙂

    All the best
    TÃ¥rd

    Awesome,

    I can confirm this works for me.

    I wanted a select drop down as a navigation.

    Works perfectly.

    Many thanks to all.

    Thanks @yuvalsabar !!
    That script did exactly what I needed!

Viewing 15 replies - 1 through 15 (of 27 total)
  • The topic ‘Request for Multiple External ReDirects’ is closed to new replies.