<?PHP
$server = "localhost"; 
$username = "root";
$password = "benk";
$database = "cma";
$mytable  = "bukutamu";

if ($database == ""){
	$query = "cma";
	if (mysql_query($query) == null){	
		$query = "CREATE DATABASE cma";
		mysql_query($query);
		$conn = mysql_connect($server,$username,$password) or die ("Could not connect MySQL"); 
		mysql_select_db($database,$conn) or die ("Could not open database");
	}
	else{
		$database= "cma";
		$conn = mysql_connect($server,$username,$password) or die ("Could not connect MySQL"); 
		mysql_select_db($database,$conn) or die ("Could not open database");		
	}	
}
else{
	$conn = mysql_connect($server,$username,$password) or die ("Could not connect MySQL"); 
	mysql_select_db($database,$conn) or die ("Could not open database");
}
?>