CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> PHP

 Database error: pconnect(mysql4.freehostia.com, robhan3_1, $DBPassword) failed. MySQL Error: 0 () Session halted

Print topic Send  topic

Author Message
gbjames

Posts: 1
Posted: 05/20/2010, 9:48 AM

I decided to change my hosting server for my website to a godaddy.com . So, why hosting it again in another server I got this error:

Database error: pconnect(mysql4.freehostia.com, robhan3_1, $DBPassword) failed. MySQL Error: 0 () Session halted. this error was on line 99:

this is the actual code:

/* establish connection, select database */
if (!$this->Connected) {
$this->Query_ID = 0;
if($this->Persistent)
$this->Link_ID=mysql_pconnect($DBHost, $DBUser, $DBPassword);
else
$this->Link_ID=mysql_connect($DBHost, $DBUser, $DBPassword);

if (!$this->Link_ID) {
$this->halt("pconnect($DBHost, $DBUser, \$DBPassword) failed.");
return 0;
}

if (!@mysql_select_db($DBDatabase,$this->Link_ID)) {
$this->halt("cannot use database ".$this->DBDatabase);
return 0;
}
$this->Connected = true;
}

return $this->Link_ID;
}


Even when I tried to use the previous server: mysql4.freehostia.com it brough this same error. Please help me out.
I can paste the full code if you need.

_________________
Curios to to know how
View profile  Send private message
mamboBROWN


Posts: 1713
Posted: 05/20/2010, 4:12 PM

gbjames,
Do you have a script that can test the database connection (Try this link: http://www.ardamis.com/2008/05/26/a-php-script-for-test...ase-connection/ )?? Try this and let me know if it works for you.
View profile  Send private message

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

PHP Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.