common/components/CartFunctionality.php
/*
     * this function checks the promotion code date
     */
this function checks the promotion code date
this function checks the promotion code date
public static function CheckDate($code_exists) {
        $date_from_user = date('Y-m-d');
        $start_ts = strtotime($code_exists->starting_date);
        $end_ts = strtotime($code_exists->expiry_date);
        $user_ts = strtotime($date_from_user);
        return (($user_ts >= $start_ts) && ($user_ts <= $end_ts));
    }
public static function CheckDate ( $ code_exists ) { $ date_from_user = date ( 'Y-m-d' ) ; $ start_ts = strtotime ( $ code_exists -> starting_date ) ; $ end_ts = strtotime ( $ code_exists -> expiry_date ) ; $ user_ts = strtotime ( $ date_from_user ) ; return ( ( $ user_ts >= $ start_ts ) && ( $ user_ts <= $ end_ts ) ) ; }
this function checks the promotion code date
this function checks the promotion code date