code: public static int compareToDDMMYYYY(String date1, String date2) {
  		if(date1.length()!=8 || date2.length()!=8) return 0;
  		return compareToDDMMYYYY0(date1)-compareToDDMMYYYY0(date2);
  	}
docs: Compare one date to another, must be in the DDMMYYYY format.
  
  @return  <0  if the first date is before the second<br>
  0   if the dates are the same or the format is invalid<br>
  >0  if the first date is after the second