did serious changes and separated most date/time components into functions