Tienes esta otra opcion :
Código PHP:
$name_check = "SELECT usuario FROM Tu_tabla WHERE usuario = '$usuario'"; // chekeamos si el usuario existe en la BD.
if (!($name_check)) print mysql_error();
$result = mysql_query($name_check);
$num_rows = mysql_num_rows($result);
if ($num_rows != 0)
{
echo "<font color='#FF0000'><b>Error </b></font><br>
<font color='red'> El usuario ".$_POST['usuario']." ya existe, por favor intente con otro</font><br>
<a href='javascript:history.back(1);'>Regresar</a>";
//include 'registrar.php';
exit();
}