title: display query error message as an alert in php?
body: <p>I have a query and its working fine:</p>
  
  <pre><code>$sql=mysql_query("UPDATE customers SET  password='$id' WHERE c_number='$users1' ");
  $result = mysql_query($sql);
  if (mysql_error()) die('Error, You have not used our services before, so no details for you to visit and explore');
  </code></pre>
  
  <p>what I want is to to display this error message in the form of some alert, or some good display.. any idea?</p>