You might already have your answer but i have done it few weeks ago and its pretty easy.
I am posting both php and c# code below, have a look:
C# Code
WWWForm form = new WWWForm();
WWW www = new WWW("url of file location on server goes here", form);
yield return www;
Debug.Log(www.text);// this should return "successful connection"
PHP Code
replace '123' with required fields
<?php
$servername = "123";
$server_username = "123";
$server_password = "123";
$dbName = "123";
//Connection
$conn = new PDO ("mysql:host=$servername;dbname=$dbName", $server_username, $server_password);
$conn->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_EXCEPTION);
//Check Connection
if(!$conn){
die("Connection failed.");
}else{
echo "Connection Successful";
}
?>
Hope its helps!