i978 Posted November 3, 2009 Share Posted November 3, 2009 我的网店,突然出现Link to database cannot be established.这会是什么原因造成的? 我的网店是:http://warestrading.com/index.php 帮主可否帮忙看一下? Link to comment Share on other sites More sharing options...
21846657 Posted November 3, 2009 Share Posted November 3, 2009 MySQL数据库链接问题。你能通过phpmyadmin登录到数据库吗? Link to comment Share on other sites More sharing options...
i978 Posted November 3, 2009 Author Share Posted November 3, 2009 MySQL数据库链接问题。你能通过phpmyadmin登录到数据库吗? 可以呀,然后呢? Link to comment Share on other sites More sharing options...
yon Posted November 3, 2009 Share Posted November 3, 2009 我的网店,突然出现Link to database cannot be established.这会是什么原因造成的? 我的网店是:http://warestrading.com/index.php 帮主可否帮忙看一下? 联系系统管理员,服务器配置问题. Link to comment Share on other sites More sharing options...
21846657 Posted November 3, 2009 Share Posted November 3, 2009 MySQL数据库链接问题。你能通过phpmyadmin登录到数据库吗? 可以呀,然后呢? 好的。这说明你的MySQL服务器没问题.接下来,打开/config/settings.inc.php,你会看到类似下面的代码: <?php define('__PS_BASE_URI__', '/'); define('_THEME_NAME_', 'YourStore'); define('_DB_NAME_', 'test'); define('_DB_SERVER_', 'localhost'); define('_DB_USER_', 'root'); define('_DB_PREFIX_', 'ps_'); define('_DB_PASSWD_', 'root'); define('_DB_TYPE_', 'MySQL'); define('_COOKIE_KEY_', 'frojuVB7wy6qICfyqskyiIS6dcwP0zRbvHZ4vKPBOosvKbZI5FVMygbN'); define('_COOKIE_IV_', 'iObbtGor'); define('_PS_VERSION_', '1.2.1.0'); ?> 在这里,你要检查你在主机管理后台设置的MySQL用户名和密码、prestashop数据库前缀、是否和你的settings.inc.php里的配置一样。 Link to comment Share on other sites More sharing options...
i978 Posted November 3, 2009 Author Share Posted November 3, 2009 MySQL数据库链接问题。你能通过phpmyadmin登录到数据库吗? 可以呀,然后呢? 好的。这说明你的MySQL服务器没问题.接下来,打开/config/settings.inc.php,你会看到类似下面的代码: <?php define('__PS_BASE_URI__', '/'); define('_THEME_NAME_', 'YourStore'); define('_DB_NAME_', 'test'); define('_DB_SERVER_', 'localhost'); define('_DB_USER_', 'root'); define('_DB_PREFIX_', 'ps_'); define('_DB_PASSWD_', 'root'); define('_DB_TYPE_', 'MySQL'); define('_COOKIE_KEY_', 'frojuVB7wy6qICfyqskyiIS6dcwP0zRbvHZ4vKPBOosvKbZI5FVMygbN'); define('_COOKIE_IV_', 'iObbtGor'); define('_PS_VERSION_', '1.2.1.0'); ?> 在这里,你要检查你在主机管理后台设置的MySQL用户名和密码、prestashop数据库前缀、是否和你的settings.inc.php里的配置一样。 非常感谢,问题已解决!备份非常重要!切记! Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now