[SCRIPT]-FILL A FORM FROM ANOTHER PAGE FORM

FILL A FORM FROM ANOTHER PAGE FORM

You can use this and make two forms on one page, hide the second using some javascript and using VUEJS’s 2 way binding / other stuff to submit the forms and handle the data on the PHP pages. This will do it without refreshing the page as well.

You can try send values over CURL when you submit first form.

function SendSecondForm($username, $password)
{
   $ch = curl_init();
   curl_setopt($ch, CURLOPT_URL,"yoursite/send.php");
   curl_setopt($ch, CURLOPT_POST, 1);
   curl_setopt($ch, CURLOPT_POSTFIELDS, "username=$username&password=$password");
   $server_output = curl_exec ($ch);
   curl_close ($ch);
}
0 0 votes
Article Rating
Subscribe
Notify of
guest
0 Comments
Inline Feedbacks
View all comments