title: mysqli_connect(): (HY000/2002): php_network_getaddresses: getaddrinfo failed: No such host is known
body: <p>I am trying to connect my local PHP program from one PC and Mysql from a server or another PC. But I got following error when I tried this</p>
  <blockquote>
  <p>Warning: mysqli_connect(): php_network_getaddresses: getaddrinfo failed: No such host is known. in D:\xampp\htdocs\bharat\bharat\connect.php</p>
  <p>Warning: mysqli_connect(): (HY000/2002): php_network_getaddresses: getaddrinfo failed: No such host is known. in D:\xampp\htdocs\bharat\bharat\connect.php</p>
  <p>Warning: mysqli_error() expects parameter 1 to be mysqli, string given in D:\xampp\htdocs\bharat\bharat\connect.php</p>
  </blockquote>
  <pre><code>&lt;?php
  $con = mysqli_connect('https://192.168.43.215', 'root', '12345678', 'bharat') or die(mysqli_error(&quot;Error connection&quot;));
  </code></pre>
  <p>I tried to keep mysql database in remote server for data security and software in local machine. Can any one tell me the exact way. Thank you.</p>