corrected a bug in consult.php (use of is.null instead of is_null)