I want a secured and server side way of interacting with two different servers namely SERVER A and SERVER B
and i want database details and queries done on server B without reveling this database details to server A but yet server A functions based on responses it got from database queries in ServerB
Then ServerB can only make a query search using data sent to it from Server A and then return a response to ServerA to know what else to do based on response it got from serverB.
My objective is this:
- The database in server B should not be know to serverA where the form is, if not i would have just added the database details inside the form in website A, since is all about quering a database and getting a result.
- The second task is to have a way to make a php run in an external server following response from another server or website.
Example, an email sending php file is on serverB but it only execute or send emails when ever serverA makes a call to it.
And probably Server A should be able to send which email address that serverA should send the email to.
A simple illustration is ServerA telling a php file in ServerB to send email to this email address. The email address to send the email to will come from a form submitted on ServerA