I need to write a login script which needs data from 2 servers databases to allow users to login.
If submitted user name and password on server's A database are OK, this script requests another php script on server B.
http://secondserver/check.php?username=$username
B server has to return 2 values:
$registration_date
$group
Then script on server A handles this user depending of values:
if ($group == "1") {
do this
} else {
do this
}
How do I get values generated by a script on different server?
P.S. Database on server B allows connections only from localhost.