0

I'm trying to get customers to fill out a particular form (form1) on my website (coded in html/javascript/css etc), and I want the data from that form to auto-populate another form (form2) which is on another website without moving the user to that website. Once the user submits form1, the data should auto-populate form2 and submit it as well. I cannot change anything about form2. There are some text fields and some drop-down options. I have exactly the same input fields in form1, but I am able to edit form1.

I have tried using WordPress plugins like Miraget, and tried coding my form1 to include "post" methods that use the 'id' of the variables. However, I cannot add "get" methods to form2. I'm unsure about how to proceed with this.

I have no working code because I don't know how to approach this problem. I just have the html code for form1 and the html code for form2 (classic html forms).

  • My approach could be (if i can) embedding the form2 into a iframe and then fill the fields with javascript gotten from form1. – JC Hernández Jul 11 '19 at 13:41
  • Possible duplicate of [HTML form with multiple "actions"](https://stackoverflow.com/questions/16660734/html-form-with-multiple-actions) – GrafiCode Jul 11 '19 at 13:43
  • Send the data to other site from server when you submit – charlietfl Jul 11 '19 at 13:50
  • @GrafiCode I think the difference is that form2's fields need to be populated automatically and submitted from form1's data. – embizzle Jul 11 '19 at 14:15
  • @JCHernández Do you know where I can find out how to do that? Will embedding form2 into an iframe allow the data to go through form2 if sent through form1? – embizzle Jul 11 '19 at 14:21
  • https://www.w3schools.com/tags/tag_iframe.asp https://stackoverflow.com/questions/39102215/how-to-show-external-website-inside-another-page-without-iframe – JC Hernández Jul 11 '19 at 22:35

1 Answers1

0


Try to send the data from form1 to PHP script, that script send data to form2.
Bye

Srsole
  • 101
  • 2
  • 3