Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Standard Formating

...

  1. December 10, 2019
  2. 10 December 2019
  3. December , 2019

Numbers

...

Only Date

  1. 2019-12-10
  2. 2019-12
  3. 2018 to 2019

...

  1. December 10 to December 25, 2019
  2. 2019-12-10 to 2019-12-25
  3. Monday to Friday, 9 a.m. to 5 p.m.

Today, Tomorrow, This weekWeek

  1. Today (December 10, 2019)
  2. Tomorrow (December 11, 2019)
  3. This week (Dec 10 to Dec 17, 2019

Time:

  1. 3 p.m.
  2. 3:25 a.m.

...

Component Refence

How to ask for date informationAsk For Date Information

The way you should ask users for dates depends on the types of date you’re asking for. When asking for a date from an existing document be sure to make the fields match the format of the existing document. This makes it easier for users to copy the date across accurately.

Dates you may need users to provide include:

...

  • dates from documents or cards, like a passport or credit card
  • approximate dates, like ‘December 2017’
  • relative dates, like ‘4 days from today’

In some cases you might need users to pick a date from a given selection.

Generally

When asking for a date from an existing document be sure to make the fields match the format of the existing document. This makes it easier for users to copy the date across accurately.

Helping

...

Users Pick a Date

Users might need to pick a date from a selection, for example, to book an appointment.

...

Never make a calendar control that depends on JavaScript as the only input option. Allow users to enter the date into a text input as well as use the control.

How to

...

Check that Dates Are Valid

To check that the dates users give you are valid, make sure that:

  • it’s a real date, for example, not 54 July
  • past dates are in the past
  • future dates are in the future
  • the first date in a date range is before the second

Handling Errors

??


Resources:

https://www.ontario.ca/document/go-its-7400-date-format

...