i have installed xampp on to my laptop, however i have another website that is online and i wanted to retrieve certain values from the database. i have tried many things to connect to the database on the website but it just doesn't seem to work.
the code that i have used to connect to the database on the website is
- Code: Select all
mysql_connect("$host", "$username", "$password")or die("cannot connect");
mysql_select_db("$db_name")or die("cannot select DB");
$sql="SELECT * FROM Users";
this is the php code i created to get the values i needed from the database which might be the issue
the error that iam getting is this
Warning: mysql_connect(): Host '220.127.116.11' is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts' in C:\xampp\htdocs\see.php on line 11
as u can see by the error the host is blocked and i have researched this issue and it seems to be due to a limit being reached, but i cant be sure of that i have tried many things like setting the firewall to allow the port for transfer and also tried to exacute a flush command (mysql flush-hosts) using the shell on the control panel but i get the error 1044 (42000): Access denied for user ''@'localhost' to database 'flush-hosts'.
i have also tried setting the limit to 10000 that got changed but the issue is still there
can anyone please help me, i have been scratching my head for ages.