Hello,
I’m in a situation where my application needs to reach a remote server and grab some data from it. It only happens when a user submits a specific form on my website.
Here’s the flow:
- User submits form
- Reach remote server
- Get some data
- Use that data
I can trust remote server. So I was wondering if it would be ok to simply do the following:
- User submits form
- Redirect to remote server
- Remote server redirects to original server with data appended to url (query string)
- Use that data
Or would it be better to do the following:
- User submits form
- cUrl request server
- Get data
- Use that data
What are the advantages of each approach (cUrl vs redirects)?