gpt4 book ai didi

找不到 phpmyadmin 主机!

转载 作者:行者123 更新时间:2023-11-29 06:18:22 28 4
gpt4 key购买 nike

您好,我正在使用 xampp,我正在尝试使用 php 进行连接。

<?php $server = localhost; $username = root; $password = ******;?>

$sql_connections = mysql_connect("$server, $username, $password") or die(mysql_error());

Warning: mysql_connect() [function.mysql-connect]: php_network_getaddresses: getaddrinfo failed: Host desconocido. in C:\xampp\htdocs\Database Manager\admin\sql_functions.php on line 17

Warning: mysql_connect() [function.mysql-connect]: [2002] php_network_getaddresses: getaddrinfo failed: Host desconocido. (trying to connect via tcp://localhost, root, usd27498:3306) in C:\xampp\htdocs\Database Manager\admin\sql_functions.php on line 17

最佳答案

您使用了不正确的符号来设置服务器:

 mysql_connect("$server, $username, $password")

需要

 mysql_connect($server, $username, $password)

manual on mysql_connect

关于找不到 phpmyadmin 主机!,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5209255/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com