Non è che c'è un firewall tra il server che ospita lo script PHP e il server con MySQL?