Abdulrahman
Abdulrahman

Reputation: 121

Build a form to send data to another

I need to build a form with a just a few fields: username, password and submit button.

Why do I need this form? In my website there is a link to let some users log into another website. In other words, I want to display a login form inside my site theme to enter login data and submit.

My question: Is there a way to send my built in form values to that form (another website form) then submit automatically?

Upvotes: 0

Views: 76

Answers (1)

Rijndael
Rijndael

Reputation: 3753

Well, there are a few ways you can approach this.

You can have the form fields on your site but the form itself points to the desired website. E.g

<form action="http://www.other-site.com/form.php">
<input type="text" name="username" />
// and so on

Or you can grab the form data on server side and use CURL to send the data.

Upvotes: 3

Related Questions