NamePros
Welcome, Guest! Ready to make a name for yourself in the domain business? We welcome both the hobbyist and professional domainer to join the discussion as part of the NamePros community.

Click here to create your profile to start earning reputation for posting, and trader ratings for buying & selling in our free e-marketplace. Build your trader rating with each successful sale. Our system has tracked over 100,000 sales and counting!
FAQ & TOS Register Search Today's Posts Mark Forums Read

Go Back   NamePros.com > Website Development Discussion Forums > Programming
Reload this Page database connect

Programming PHP, Perl, Ruby on Rails, AJAX, HTML, XHTML, CSS, JavaScript, MySQL and any other coding topics.

Advanced Search


Closed Thread
 
LinkBack Thread Tools
Old 11-04-2004, 02:17 PM THREAD STARTER               #1 (permalink)
NamePros Expert
 
redhippo's Avatar
Join Date: Oct 2003
Location: ANForum
Posts: 5,218
redhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to behold
 



Talking database connect


Warning: mysql_connect(): Access denied for user: 'box@localhost' (Using password: YES) in /home/lembu/public_html/config.php on line 15
Cannot connect to the database.

whats wrong?
how do i set the mysql data base/\?
__________________
|www.vb-skins.com|- Quality Premade Vbulletin skins for Your VB forum makeover |www.Banjir.com|-Free image hosting?[B]For Sale!|AlphaScripts|Money Generating Scripts
FREE VB Skins
redhippo is offline  
Old 11-04-2004, 02:38 PM   #2 (permalink)
NamePros Regular
Join Date: Aug 2003
Location: UK
Posts: 568
Tjobbe is on a distinguished road
 



whats wrong?
how do i set the mysql data base/\?




connecting to the database usually is by enterring your username followed by the db name/ db username:

such as:

username_dbname

username_dbusername

password


if your ftp username is "sitename" and your database is called "frogs", your db username and password are "tanks" and "bangers" resoectively, then it would look like this:

sitename_frogs

sitename_tanks

bangers


hope this helps!
__________________
Web Site Design | Web Designers Blog
Tjobbe is offline  
Old 11-04-2004, 02:50 PM   #3 (permalink)
RJ
NamePros Webmaster


 
RJ's Avatar
Join Date: Feb 2003
Posts: 12,930
RJ Has achieved greatnessRJ Has achieved greatnessRJ Has achieved greatnessRJ Has achieved greatnessRJ Has achieved greatnessRJ Has achieved greatnessRJ Has achieved greatnessRJ Has achieved greatnessRJ Has achieved greatnessRJ Has achieved greatnessRJ Has achieved greatness
 



Find Marrow Donors! Cystic Fibrosis Parkinson's Disease
Edit your config.php file and replace the values for database name, database username and password with the correct settings for your database. Those settings are provided to you by your webhost, or setup by you through your web hosting control panel.

For example, code used with PHP to connect to a MySQL database:

PHP Code:
$dbuser "database username";
$dbpass "database password";
$dbname "database name";
????: NamePros.com http://www.namepros.com/programming/54285-database-connect.html
$dbhost "localhost";

mysql_connect($dbhost,$dbuser,$dbpass);
mysql_select_db($dbname) or die("Unable to select database"); 
Replace the values for the first three lines with the correct settings for your database.
__________________
@DomainBuyer facebook
RJ is offline  
Old 11-04-2004, 05:06 PM   #4 (permalink)
Senior Member
 
OxDomains's Avatar
Join Date: Sep 2003
Location: NYC
Posts: 2,481
OxDomains has a brilliant futureOxDomains has a brilliant futureOxDomains has a brilliant futureOxDomains has a brilliant futureOxDomains has a brilliant futureOxDomains has a brilliant futureOxDomains has a brilliant futureOxDomains has a brilliant futureOxDomains has a brilliant futureOxDomains has a brilliant futureOxDomains has a brilliant future
 



let me know if you need some help- i will gladly help you out
__________________
FHAMortgage.us.com is for Sale
OxDomains is offline  
Old 11-05-2004, 02:10 AM THREAD STARTER               #5 (permalink)
NamePros Expert
 
redhippo's Avatar
Join Date: Oct 2003
Location: ANForum
Posts: 5,218
redhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to behold
 



thanks all...fixed
__________________
|www.vb-skins.com|- Quality Premade Vbulletin skins for Your VB forum makeover |www.Banjir.com|-Free image hosting?[B]For Sale!|AlphaScripts|Money Generating Scripts
FREE VB Skins
redhippo is offline  
Old 11-07-2004, 08:44 PM THREAD STARTER               #6 (permalink)
NamePros Expert
 
redhippo's Avatar
Join Date: Oct 2003
Location: ANForum
Posts: 5,218
redhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to behold
 



have another similiar problem...anyone can help me now?? on msn?
__________________
|www.vb-skins.com|- Quality Premade Vbulletin skins for Your VB forum makeover |www.Banjir.com|-Free image hosting?[B]For Sale!|AlphaScripts|Money Generating Scripts
FREE VB Skins
redhippo is offline  
Old 11-26-2004, 11:49 AM THREAD STARTER               #7 (permalink)
NamePros Expert
 
redhippo's Avatar
Join Date: Oct 2003
Location: ANForum
Posts: 5,218
redhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to beholdredhippo is a splendid one to behold
 



Sad Error 1044


Originally Posted by -RJ-
Edit your config.php file and replace the values for database name, database username and password with the correct settings for your database. Those settings are provided to you by your webhost, or setup by you through your web hosting control panel.

For example, code used with PHP to connect to a MySQL database:

PHP Code:
$dbuser "database username";
$dbpass "database password";
$dbname "database name";
$dbhost "localhost";

mysql_connect($dbhost,$dbuser,$dbpass);
mysql_select_db($dbname) or die("Unable to select database"); 
????: NamePros.com http://www.namepros.com/showthread.php?t=54285
Replace the values for the first three lines with the correct settings for your database.

i have done that but i get this now:

Attempting to attach to database

Connect failed: unexpected error from the database.

Error number: 1044

Error description: Access denied for user: 'anforum_perawan@localhost' to database 'anforum_forum'

Please ensure that the database and server is correctly configured and try again.
__________________
|www.vb-skins.com|- Quality Premade Vbulletin skins for Your VB forum makeover |www.Banjir.com|-Free image hosting?[B]For Sale!|AlphaScripts|Money Generating Scripts
FREE VB Skins
redhippo is offline  
Old 11-26-2004, 03:42 PM   #8 (permalink)
Account Closed
 
Sergio965's Avatar
Join Date: Apr 2004
Location: ~root
Posts: 1,091
Sergio965 is a splendid one to beholdSergio965 is a splendid one to beholdSergio965 is a splendid one to beholdSergio965 is a splendid one to beholdSergio965 is a splendid one to beholdSergio965 is a splendid one to beholdSergio965 is a splendid one to behold
 



Fixed It
Sergio965 is offline  
Old 11-26-2004, 03:43 PM   #9 (permalink)
NamePros Regular
 
CreativeLogic's Avatar
Join Date: Sep 2003
Posts: 890
CreativeLogic has a spectacular aura aboutCreativeLogic has a spectacular aura about
 



You need to give that user permissions for that database!
__________________
Online Time Tracking :)
CreativeLogic is offline  
Old 11-26-2004, 09:34 PM   #10 (permalink)
NamePros Expert
 
Peter's Avatar
Join Date: Nov 2003
Location: Scotland
Posts: 5,069
Peter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond reputePeter has a reputation beyond repute
 


Child Abuse Save The Children Save The Children Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009 Help The Homeless - Holiday 2009
Originally Posted by Tjobbe
whats wrong?
????: NamePros.com http://www.namepros.com/showthread.php?t=54285
how do i set the mysql data base/\?




connecting to the database usually is by enterring your username followed by the db name/ db username:

such as:

username_dbname

username_dbusername

password


if your ftp username is "sitename" and your database is called "frogs", your db username and password are "tanks" and "bangers" resoectively, then it would look like this:

sitename_frogs

sitename_tanks

bangers


hope this helps!

You seem to be assuming he is using cpanel but a database name does not always bear any relation to the account details of the ftp or control panel.
__________________
Manage your portfolio using my new Domain Portfolio Management script.
Securing Your Domain Name From Theft
Peter is offline  
Closed Thread


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools


Liquid Web Smart Servers  
All times are GMT -7. The time now is 01:10 PM.

Managed Web Hosting by Liquid Web
Domain name forum recommended by Domaining.com Powered by: vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.6.0 Ad Management plugin by RedTyger