edraconus Posted December 13, 2012 Share Posted December 13, 2012 I couldn't find this mentioned before, so sorry if it has been asked. After using the mysql and mysqli functions for connecting too the database and for the past 2 years the PDO class, I decided to use the MySQLi class. Following the examples in the book I keep getting the following error -: mysqli::mysqli(): php_network_getaddresses: getaddrinfo failed: No such host is known. I am running the script on my Apache Friends xampp server with localhost. The script runs perfectly ok using the mysqli functions and the pdo class. I have googled the error and have performed the various checks suggested in a few of the posts, but still get the same error. PHP version 5.4.7, MYSQL version 5.5.27 Link to comment Share on other sites More sharing options...
edraconus Posted December 14, 2012 Author Share Posted December 14, 2012 Managed to work out the error, a simple mistake, which I had missed. Link to comment Share on other sites More sharing options...
Larry Posted December 14, 2012 Share Posted December 14, 2012 Glad you got it working. For future reference, please post any applicable code along with your question, and then post the solution when you get it working. Link to comment Share on other sites More sharing options...
Recommended Posts