Javascript testing an array, string, int is empty, null or 0
Javascript test if input is a valid date