Re: mysql_commect or die

2006-03-11 Thread Peter Brawley
fbsd_user wrote: mysql_connect("localhost","root") or die("Unable to connect to MySQL server"); $err mysql_connect("localhost","root"); if ($err != 0) { Under what conditions will the die clause be taken. What is in $err if there is a error? Are these 2 statements basically d

RE: mysql_commect or die

2006-03-11 Thread Ing. Edwin Cruz
mysql_connect("localhost","root") or die("Unable to connect to MySQL server"); $err = mysql_connect("localhost","root"); if ($err != 0) { Mysql_connect returns a link to a identifier of the conection, also returns 0 when the conection could not be estabished, When you do: $err