Erreur : SQLSTATE[HY000] [2002] php_network_getaddresses: getaddrinfo failed: No address associated with hostname

Bonjour, je vous contacte car je reçois une erreur quand j’essaie de me connecter a la base de données de mon site.

ERROR:

Erreur : SQLSTATE[HY000] [2002] php_network_getaddresses: getaddrinfo failed: No address associated with hostname

Je vous prie de m’aider. Cordialement.

Hello and welcome. Please type in English on this forum.

Can you please give some additional detail, such as the name of the program used, and how you are trying to connect?
Thanks

1 Like

I created a member area, with registration and login form. When I use the registration page an error puts me “No address associated with hostname”

There is a connection problem with the database

URL?
How are you connecting?
What code are you using?

That could possible be the problem, but I can’t say until, you give enough info. Have you read the pinned topics?

When I try to connect to my database it doesn’t work.

<?php try { $bdd = new PDO('mysql:host=sql205.epizy.com;dbname=epiz_*********_users;charset=utf8', 'epiz_*********', '************'); } catch(PDOException $e) { die('Erreur : '.$e->getMessage()); }

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.