TheOne
09-15-2006, 07:43 PM
Hey,
Its been a while since ive used mysql and php, so im trying to relean and finish off a script i made a while ago. ive not hosted it online before, just used to use my own machine. Whilst trying to connect to the db currently on vistapages i get the error:
Can't use database : Access denied for user '*accountname*_*dbusername*'@'localhost' to database 'xxx'
or just an Error connecting
now got a few questions, am i supposed to have my script connectin from localhost, or does it need to use an IP etc? When i created a username/pass in cpanel, it put my account name first then an underscore and the username, i am guessing i need to use the whole thing incuding _ as the $db_user. so i need to do anything to the password aswell? and finally, the $db_name, do i need to do anything here, is it the same as what i typed in the new database field in cpanel? in my case hockey, does it stay the same.
Thanks
Its been a while since ive used mysql and php, so im trying to relean and finish off a script i made a while ago. ive not hosted it online before, just used to use my own machine. Whilst trying to connect to the db currently on vistapages i get the error:
Can't use database : Access denied for user '*accountname*_*dbusername*'@'localhost' to database 'xxx'
or just an Error connecting
now got a few questions, am i supposed to have my script connectin from localhost, or does it need to use an IP etc? When i created a username/pass in cpanel, it put my account name first then an underscore and the username, i am guessing i need to use the whole thing incuding _ as the $db_user. so i need to do anything to the password aswell? and finally, the $db_name, do i need to do anything here, is it the same as what i typed in the new database field in cpanel? in my case hockey, does it stay the same.
Thanks