PHP question: controlling Arduino over Ethernet using LAMP

The way you can do it is change a SQL variable in database and conitnously just poll the script in arduino with a GET element and put that variable from your webserver to the similar variable defined in your uC programme and then utilise a IF statement to take action that's , What you have done already I have done that with both Ethernet ,WiFi and GPRS as well, I personally like to develop Internet of things systems with GPRS internet.