I would use an AJAX request to a PHP script that does the lookup, which might look something like this on the jQuery side after document ready:
// jquery
$('#email-input').live('change', function() {
//ajax request
$.ajax({
url: "email_check.php",
data: {
'email' : $('#email-input').val()
},
dataType: 'json',
success: function(data) {
if(data.result) {
alert('Email exists!');
}
else {
alert('Email doesnt!');
}
},
error: function(data){
//error
}
});
});
With the example above your PHP would have to return json data once its done the email check based on the address, for example your email_check.php would contain:
// get email passed via AJAX
$email = $_GET['email'];
// do check
if ( email_exists($email) ) {
$response->result = true;
}
else {
$response->result = false;
}
// echo json
echo json_encode($response);
Hope that helps!