skip to Main Content

I have wrote a simple program which uses MySQL db server of XAMPP. Program works fine when I connect to ‘localhost’:

enter image description here

But when I try connect a MySQL db from another computer (in my LAN):

enter image description here

it gives below error:

enter image description here

But I can connect to that ‘phpmyadmin’ from browser:

enter image description here

(or Can it be that the computers which I’m testing are domain members ?)

2

Answers


  1. Chosen as BEST ANSWER

    Actually the problem was, MySQL server settings has set to work only for local connections (by default):

    enter image description here

    So, then I uncommented the second line and chanded to:

    enter image description here

    And it worked. '127.0.0.1' means localhost and '0.0.0.0' means any host


  2. Please check your Firewall on the remote machine. It might block the mysql connection and has an exception rule for HTTP Ports, thats why phpMyAdmin is reachable.

    Login or Signup to reply.
Please signup or login to give your own answer.
Back To Top
Search