/* Code by iVane Hwang. ivane.hwang@googlemail.com */
$(function(){
  $('#OBF input, #OBF select, #OBF textarea').focus(function() {
	  $(this).addClass("input-now")
	  });
  $('#OBF input, #OBF select, #OBF textarea').blur(function() {
	  $(this).removeClass("input-now")
	  });
});
$.validator.setDefaults({ });
$().ready(function() {
	$("#Free_Airport_Pickup_Arrangement").validate({
	   event: "keyup",
	   rules: {
         ArrivalDate: "required",
		 ArrivalTimeHour: "required",
		 ArrivalTimeMinute: "required",
		 FlightNumber: "required",
		 DepartureCity: "required",
		 NumberofPassengers: "required",
		 MailAddress: {required: true,email: true},
		 EmergencyContactNumber: "required",
		 BookingIdNumberOnConfirmationLetter: "required",
		 _fm_captcha_text: "required"
	   },
	   messages: {
         ArrivalDate: "Please choose the arrival date!",
		 ArrivalTimeHour: "Please choose the arrival time hour!",
		 ArrivalTimeMinute: "Please choose the arrival time minute!",
		 FlightNumber: "Please input the flight number!",
		 DepartureCity: "Please input the departure city!",
		 NumberofPassengers: "Please choose the number of passengers",
		 MailAddress: "Please input the mail address!",
		 EmergencyContactNumber: "Please input the emergency contact number!",
		 BookingIdNumberOnConfirmationLetter: "Please input the booking id number on confirmation letter!",
		 _fm_captcha_text: "Please input the the text that you can see from the image!"
	   }
	});
});