updated function for mysqli_real_escape_string