(date)
return timegm(date.timetuple())
Converts a datetime to a Unix timestamp , like: 1400566301.

    Parameters:
    date -- a `datetime` instance.
Converts a datetime to a Unix timestamp , like: 1400566301.
Converts a datetime to a Unix timestamp like : 1400566301 .
def datetime_to_unix(date):
    """
    Converts a datetime to a Unix timestamp , like: 1400566301.

    Parameters:
    date -- a `datetime` instance.
    """
    return timegm(date.timetuple())
def datetime_to_unix ( date ) : return timegm ( date . timetuple ( ) )