U moet poort 3306 openen om verbindingen te accepteren.
$dsn = "mysql:host=mysite.com;dbname=some_db;charset=utf8";
$opt = array(
PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION,
PDO::ATTR_DEFAULT_FETCH_MODE => PDO::FETCH_ASSOC
);
$pdo = new PDO($dsn,'Username','Password', $opt);