common/utilities/DateUtil.php
public static function inBetween( $startDate, $endDate, $date ) {

		$start 	= is_string( $startDate ) ? strtotime( $startDate ) : $startDate->getTimestamp();
		$end 	= is_string( $endDate ) ? strtotime( $endDate ) : $endDate->getTimestamp();
		$test 	= is_string( $date ) ? strtotime( $date ) : $date->getTimestamp();

		// Test in between start and end
		return ( ( $test >= $start ) && ( $test <= $end ) );
	}
public static function inBetween( $startDate, $endDate, $date ) {

		$start 	= is_string( $startDate ) ? strtotime( $startDate ) : $startDate->getTimestamp();
		$end 	= is_string( $endDate ) ? strtotime( $endDate ) : $endDate->getTimestamp();
		$test 	= is_string( $date ) ? strtotime( $date ) : $date->getTimestamp();

		// Test in between start and end
		return ( ( $test >= $start ) && ( $test <= $end ) );
	}
public static function inBetween ( $ startDate , $ endDate , $ date ) { $ start = is_string ( $ startDate ) ? strtotime ( $ startDate ) : $ startDate -> getTimestamp ( ) ; $ end = is_string ( $ endDate ) ? strtotime ( $ endDate ) : $ endDate -> getTimestamp ( ) ; $ test = is_string ( $ date ) ? strtotime ( $ date ) : $ date -> getTimestamp ( ) ; // Test in between start and end return ( ( $ test >= $ start ) && ( $ test <= $ end ) ) ; }
Compare the given date and check whether it's between the start date and end date.

@param type $startDate
@param type $endDate
@param type $date
@return type
Compare the given date and check whether it s between the start date and end date .