0

I use this code:

<?php
    $link = mysql_connect('nibiru.zarea.net/sqladmin', 'czoctopus','*******');
    if (!$link) {
        die('<h1>Mysql error: ' . mysql_error() . '</h1>');
    }
?>

this is echo:

Mysql error: php_network_getaddresses: getaddrinfo failed: Name or service not known

1 Answer 1

1

This

 example.com/sqladmin

is not a valid server address. You probably need to use the domain only (or ask your provider for the address of the database server).

Sign up to request clarification or add additional context in comments.

1 Comment

nibiru.zarea.net/sqladmin this is not ms sql :). Get the actual host name of the mysql server. if it is on the same box, try localhost.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.