PHP Tool using Sockets