Arduino Yun Connecting to MySQL

I'm working on a project, where I want to take an input text from the Arduino Yun and send it to the MySQL to perform a search (to match the input with an existing data item) and delete algorithm on a table. The server should send a response back to the Arduino signalling whether or not the data given as input has matched with an existing data item in the database. What different programming modules do I need to implement this system? I heard that I can use PHP to do this, but I am not sure how. Any help is much appreciated!