Webtags (preserving history): Difference between revisions

m
m (→‎Yearly: Correction)
Line 34: Line 34:


Although in theory you can specify date formatting to times and vice versa, this will not always yield a sensible result. It is best to look at the default format. For example the time-stamps for today and yesterday only contain time information, so only time-based format instructions should be applied to them.
Although in theory you can specify date formatting to times and vice versa, this will not always yield a sensible result. It is best to look at the default format. For example the time-stamps for today and yesterday only contain time information, so only time-based format instructions should be applied to them.
'''Differences between Cumulus 1 and Cumulus MX (Cumulus 3):'''
*Cumulus MX uses the .NET date and time format characters that are not exactly the same as the Delphi ones which Cumulus 1 uses.  For Cumulus MX see [[http://msdn.microsoft.com/en-us/library/8kb3ddd4(v=vs.110).aspx here for format selectors]]. The differences come about because Delphi is case-insensitive, and .Net is case sensitive, so .Net can use upper and lower case for different items, where Delphi has to use different letters. For example, in Delphi, "nn" means "minutes", and this will need changing to "mm". "hh" in Delphi is the hour in 24-hour format, and in .Net it's "HH".
*The other change with the "format" parameter is the different way that .Net escapes characters which are not to used as format specifiers. In Delphi you put the 'verbatim' characters inside single quotes; in .Net you escape each verbatim character with backslashes.
'''The Rest of this section applies only to Cumulus 1'''


You should put anything which is not intended to be part of the date and time formatting into single quotation marks to prevent it being interpreted as a date or time formatter. For example, the word "on" contains the character "n", which will be interpreted as a time formatter unless you put it into single quotation marks. Example: <#TtempH format="'at' hh: mm 'on' dd / mm / yyyy">.  You can include HTML tags (but they cannot have any attributes because both single and double quote characters have defined meanings) and special characters as quoted text within the 'format' parameter.  Example: <#TapptempH format="'at 'h:nn'&nbsp;'am/pm '<small>on' d/m/yyyy'</small>'">.
You should put anything which is not intended to be part of the date and time formatting into single quotation marks to prevent it being interpreted as a date or time formatter. For example, the word "on" contains the character "n", which will be interpreted as a time formatter unless you put it into single quotation marks. Example: <#TtempH format="'at' hh: mm 'on' dd / mm / yyyy">.  You can include HTML tags (but they cannot have any attributes because both single and double quote characters have defined meanings) and special characters as quoted text within the 'format' parameter.  Example: <#TapptempH format="'at 'h:nn'&nbsp;'am/pm '<small>on' d/m/yyyy'</small>'">.
5,838

edits