inherit
46457
0
Sept 15, 2020 4:22:02 GMT -8
Austen
Hi
8,015
June 2005
austendale
|
Post by Austen on Jul 17, 2011 8:41:51 GMT -8
Well, I'm attempting to make a connection to my database, and I've never had this error before so I don't know how to deal with it, and my webhost says my phpmyadmin is working, and don't understand that that's not the problem D:
Warning: mysql_connect() [function.mysql-connect]: Host 'srv11.000webhost.com' is not allowed to connect to this MySQL server in /home/a9448809/public_html/shoutboxtemplate.php on line 108
D: Any help?
|
|
inherit
130228
0
Jul 11, 2024 19:19:59 GMT -8
Charles Stover
1,731
August 2008
gamechief
|
Post by Charles Stover on Jul 17, 2011 9:13:09 GMT -8
Can you post the mysql_connect() line of your code (taking out your password, of course)?
If I'm not mistaken, 000webhost tells you your MySQL information in a sidebar in the admin CP.
You will need either: mysql_connect('localhost', 'etc', 'etc');
Or: mysql_connect('what is in the admin cp', 'etc', 'etc');
I think they use a subdomain for their MySQL server instead of just using localhost. You pretty much just have to copy-paste it from their sidebar.
|
|
inherit
46457
0
Sept 15, 2020 4:22:02 GMT -8
Austen
Hi
8,015
June 2005
austendale
|
Post by Austen on Jul 17, 2011 9:17:11 GMT -8
mysql_connect("mysql_host", "$mysql_user", "$mysql_password") or die(mysql_error()); mysql_select_db("$mysql_database") or die(mysql_error());
I have the details COPIED from the Control Panel so it can't be wrong.
LOL! I'm pretty stupid ... Forgot the $ D:
|
|
inherit
46457
0
Sept 15, 2020 4:22:02 GMT -8
Austen
Hi
8,015
June 2005
austendale
|
Post by Austen on Jul 17, 2011 9:43:01 GMT -8
I fixed that error, now I'm getting
Warning: mysql_connect() [function.mysql-connect]: Access denied for user 'a9448809'@'localhost' (using password: NO) in /home/a9448809/public_html/shoutboxtemplate.php on line 108
Access denied for user 'a9448809'@'localhost' (using password: NO)
|
|
inherit
130228
0
Jul 11, 2024 19:19:59 GMT -8
Charles Stover
1,731
August 2008
gamechief
|
Post by Charles Stover on Jul 18, 2011 7:55:15 GMT -8
When I asked for mysql_connect, I mostly wanted to see the MySQL host to see if it was localhost or a subdomain. But oh well, you got that fixed.
Your problem now is that you don't have the MySQL password entered.
|
|
inherit
97216
0
Nov 26, 2024 13:53:14 GMT -8
Bennett 🚀
Formerly iPokemon.
3,622
January 2007
catattack
iPokemon's Mini-Profile
|
Post by Bennett 🚀 on Aug 3, 2011 18:56:06 GMT -8
When I asked for mysql_connect, I mostly wanted to see the MySQL host to see if it was localhost or a subdomain. But oh well, you got that fixed. Your problem now is that you don't have the MySQL password entered. This, or you haven't created the user yet.
|
|
inherit
Proboards Legend
12897
0
Oct 16, 2016 6:49:45 GMT -8
Snakeair
I don't know what to write here.
40,721
August 2003
snakeair
|
Post by Snakeair on Aug 4, 2011 21:45:07 GMT -8
000webhost is a bad host to have. I once had a wordpress plugin that broke one of my tables in mysql and instead of me fixing it because i was lazy that day, i contact hostgator live support tech and in 5 minutes it was fixed and i found out the 2 plugins that was not compatiable.
Sometimes ones website/blog out grow's a host or there shared hosting packages. If i get bad support from a host a few times then i change hosts.
Sorry i took the thread offtopic a little.
|
|