Vote count:
0
I am getting the below warning everytime I try to access other server. But when I access again the below error is gone.
What I have tried:
I have used host IP address instead of Host name but it still did not resolve.
When does this Occur
1. When I try to use file_get_html(..);
2. When I try to use ftp_connect(..);
Warning Message:
file_get_contents(): php_network_getaddresses: getaddrinfo failed: Name or service not known
asked 3 mins ago
1 Answer
Vote count:
0
If you are getting the error in file_get_contents(), it means the file from which you are trying to get the content is not accessible.
file_get_contents($path_of_file);
Check the path properly and also the permission of the file.
answered 23 secs ago
PHP getaddrinfo issue
Aucun commentaire:
Enregistrer un commentaire