date formatting and front formatting