public function toTimestamp(string $date, string $time = ''): int
    {
        if (empty($time)) {
            $time = '00:00:01';
        }
        
        // create unix_timestamp
        return strtotime($date . ' ' . $time);
    }
public function toTimestamp(string $date, string $time = ''): int
    {
        if (empty($time)) {
            $time = '00:00:01';
        }
        
        // create unix_timestamp
        return strtotime($date . ' ' . $time);
    }
public function toTimestamp ( string $ date , string $ time = '' ) : int { if ( empty ( $ time ) ) { $ time = '00:00:01' ; } // create unix_timestamp return strtotime ( $ date . ' ' . $ time ) ; }
Converts a date and time string into timestamp

@param string $date
@param string $time

@return number
Converts a date and time string into timestamp