mysql_error()

It returns the error description of the last MySQL operation

Example

<?php
$conn = mysql_connect(“localhost”, “root”, “password”) or die(mysql_error());
?>

Share