Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]
Hi
I am currently doing a web project using wamp5. Right now this is how
i am connecting to the database:Code: Select all
$con = mysql_connect("localhost", "root", "");
if (!con) {
die('Could not Connect' . mysql_error());
}
if (!mysql_select_db("Leave", $con)){
die (mysql_error());
}
else {
.......
}When the code above is activated, this is the result: ---> "Unknown database 'leave' "
Right now i am looking at 3 possibilities:
1)Could there be anything in mysql that i might have done wrong that triggers the error?
2)There is a problem in my $con object in the 1st place?
3)Certain configurations in e SQLite may hav sth to do with tis. (yes, the error message refers to "leave"
whilst the db select call is for "Leave")
Help is much appreciated
feyd | Please use
Code: Select all
,Code: Select all
and [syntax="..."] tags where appropriate when posting code. Your post has been edited to reflect how we'd like it posted. Please read: [url=http://forums.devnetwork.net/viewtopic.php?t=21171]Posting Code in the Forums[/url] to learn how to do it too.[/color]