PHP error: php_network_getaddresses: getaddrinfo failed: (while getting information from other site.)

后端 未结 11 1134
时光说笑
时光说笑 2020-12-01 10:18

Trying to get information from an external source, I\'m receiving the following error:

Warning: php_network_getaddresses: getaddrinfo

11条回答
  •  不知归路
    2020-12-01 10:56

    I faced this issue, while connecting DB, the variable to connect to db was not defined.

    Cause: php tried to connect to the db with undefined variable for db host (localhost/127.0.0.1/... any other ip or domain) but failed to trace the domain.

    Solution: Make sure the db host is properly defined.

提交回复
热议问题