coppermine-gallery.com/forum

Support => cpg1.3.x Support => Older/other versions => cpg1.3 Installation & Setup => Topic started by: SteveToms on March 24, 2005, 02:28:54 AM

Title: Won't Install
Post by: SteveToms on March 24, 2005, 02:28:54 AM
Could not create a mySQL connection, please check the SQL values entered

MySQL error was : Unknown MySQL server host '*** ' (1
Title: Re: Won't Install
Post by: Tranz on March 24, 2005, 02:40:28 AM
Have you confirmed with your webhost that the settings are correct?
Title: Re: Won't Install
Post by: SteveToms on March 24, 2005, 03:15:08 AM
I have installed phpbb and php nuke so yes. This is just a new db
Title: Re: Won't Install
Post by: kegobeer on March 24, 2005, 04:13:06 AM
Make a test php file with this:

<?php
$localhost 
'your host name';
$mysql_user 'your mysql user name';
$mysql_password 'your mysql password';
$mysql_database 'your mysql database name';

$link mysql_connect($localhost$mysql_user$mysql_password);
if (!
$link) {
   die(
'Could not connect: ' mysql_error());
}
echo 
'Connected successfully<br />';

$db_selected mysql_select_db($mysql_database$link);
if (!
$db_selected) {
   die (
'Can\'t use ' $mysql_database ': ' mysql_error());
}
mysql_close($link);
?>


Put in your information.  Do you get a connection?
Title: Re: Won't Install
Post by: SteveToms on March 24, 2005, 05:10:43 AM
I got it too work, new db created. I guess my other one did not want to work
Title: Re: Won't Install
Post by: btos on May 04, 2005, 06:46:12 AM
I wish I could understand how this fix was done. How is the php file named and where does it go? I have a similar problem and have been trying for hours to find an answer and this is about as close as I have come yet.