I need a PHP script that receives a GET variable and wont finish its execution until another instance calls the same script with the exact same GET variable.
Once it matches, both instances must print "ok".
- Computer 01 calls [login to view URL]
- This script will stay loading
- Computer 02 calls [login to view URL]
- Both computers that are using the ID 123 will receive an "ok" at exact the same time.
It is VERY important that the first computer script waits for the second computer call in order to finish the script execution for both.
The execution end must happen exact at the same time for both computers, otherwise, our solution wont work.
Think of it as a way to synchronize 2 different devices through the internet.
Our environment is Windows+IIS+PHP7