added function (callback) to change date format