Temos pavadinimas: WordPress, Shopify ir PHPFusion programuotojų bendruomenė :: Nepagaunu kampo..

Parašė Inspire· 2012 Sau. 4 19:01:38
#1

Tai vat bandau priijungt prie DB ir vis gaunu error...


Warning: Missing argument 1 for dbconnect(), called in C:\Program Files\EasyPHP-5.3.2i\www\tst.php on line 3 and defined in C:\Program Files\EasyPHP-5.3.2i\www\core.php on line 6

Warning: Missing argument 2 for dbconnect(), called in C:\Program Files\EasyPHP-5.3.2i\www\tst.php on line 3 and defined in C:\Program Files\EasyPHP-5.3.2i\www\core.php on line 6

Warning: Missing argument 3 for dbconnect(), called in C:\Program Files\EasyPHP-5.3.2i\www\tst.php on line 3 and defined in C:\Program Files\EasyPHP-5.3.2i\www\core.php on line 6





Kodas:

 
<?php
$db_host = "127.0.0.1";
$db_user = "root";
$db_pass = "";
 
function dbconnect($db_host, $db_user, $db_pass) {
	$db_connect = mysql_connect($db_host, $db_user, $db_pass);
	if (!$db_connect) {
		die("Nepavyko prisijungti prie DB<br />".mysql_error());
	}
}
?>