Jump to content

Changing date formats

Date formats in IPS 4 can be formatted and translated by changing language strings to any format you wish to show them in. You can find date related strings prefixed with _date within your language pack.

If you are unsure on how to manually translate language strings, you will need to read the following guide first of all

Language strings are made up of separate elements relating to the day, month, and year. In this example I will be editing the language string _date_last_year_long .

The default for this is as follows, which I will explain in parts

 {!1#[1:January][2:February][3:March][4:April][5:May][6:June][7:July][8:August][9:September][10:October][11:November][12:December]} {0#} %s

 

Re-formatting

To explain this I have colorized the relevant items within the language string we are using as an example

{!1#[1:January][2:February][3:March][4:April][5:May][6:June][7:July][8:August][9:September][10:October][11:November][12:December]} {0#} %s

In this example we have 3 parts, and I will explain this showing March 1 2016

RED - This is the simplest of the 3 sections, as you can see the months clearly. This is the "March" month part of the string above

BLUE - This is the day part of the string, in this case simply the number 1.

PURPLE - This represents the year part of the above date, being 2016

As you can see here, you can quite simply rearrange the above by changing the order in which the parts are set within your language string. So if we wanted to switch this to "1 March 2016" we would re-arranged as follows. Again colorized to emphasize the individual parts.

{0#} {!1#[1:January][2:February][3:March][4:April][5:May][6:June][7:July][8:August][9:September][10:October][11:November][12:December]} %s

Tip

You will note before the months that there is a  "{!1#" displayed. This means that it will not display the numbers in that section, so will only show February for the language string part, rather than showing the number 2 

 

Note: Some dates are controlled by the locale set within your language pack. You can edit this from Customization>Localization>Languages, by selecting the edit button on your language pack

Edited by Marc Stridgen

  Report Guide


×
×
  • Create New...