ho provato a metterlo così ma il problema sussiste.
class MySQL
{
function connect()
{
$this->host_name = "xxx";
$this->user_name = "xxx";
$this->password = "xxx";
$this->data_name = "xxx";
$this->link = mysql_connect($this->host_name, $this->user_name, $this->password) or die (mysq_error());
mysql_select_db($this->data_name) or die (mysq_error());
mysql_set_charset('utf8',$this->link);
}
}