CodeIgniter Forums
Database error - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20)
+--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23)
+--- Thread: Database error (/showthread.php?tid=32690)



Database error - El Forum - 07-31-2010

[eluser]rijobo[/eluser]
Hello,

I've seen this error lots of times, but I can't find my solution.
I've installed WAMP and CI. When I try to connect to my mysql database on my WAMP, I get this error:


A Database Error Occurred

Unable to connect to your database server using the provided settings.

When I've got WAMP on my local pc, what do I need to fill in in my database.php?


Database error - El Forum - 08-01-2010

[eluser]Jan_1[/eluser]
Code:
<?php
$db_server = "localhost";
$db_user = "root";
$db_passwort = "";
$db = mysql_connect($db_server,$db_user,$db_passwort);
if($db) {  echo "that works"; }
else    {  echo "what have i done before ?"; }
?>

is that a help?


Database error - El Forum - 08-01-2010

[eluser]rijobo[/eluser]
I get an access denied. Hoe can I see which user I need to use? When I go to my phpmyadmin, I don't need to insert a user.
Don't you also need a db in the above example?


Database error - El Forum - 08-01-2010

[eluser]Jan_1[/eluser]
if i do understand you, yes, start with making an db in phpmyadmin


Database error - El Forum - 08-01-2010

[eluser]rijobo[/eluser]
Sorry, I didn't read very well. I needed to use the user root.
Thanks for your help.