The jstrftime() function formats the broken-down jalali time jtm according to the format specification
format and places the result in the character array s of size max.
The format specification is a null-terminated string and may contain special character sequences called
conversionspecifications, each of which is introduced by a '%' character and terminated by some other
character known as a conversionspecifiercharacter. All other character sequences are ordinarycharactersequences.
The characters of ordinary character sequences (including the null byte) are copied verbatim from format
to s. However, the characters of conversion specifications are replaced as follows:
%a The abbreviated weekday name.
%A The full weekday name.
%b The abbreviated month name.
%B The full month name.
%c The preferred date and time representation.
%C The century number (year/100) as a 2-digit integer.
%d The day of the month as a decimal number (range 01 to 31).
%D Equivalent to %Y/%m/%d.
%e Like %d The day of the month as a decimal number, but a leading zero is replaced by a space. (SU)
%E The preferred date and time in Farsi. (utf8)
%F Equivalent to %Y-%m-%d (similar to the ISO 8601 date format). (C99)
%h The abbreviated Farsi transliterated weekday name.
%q The full Farsi transliterated weekday name.
%g The abbreviated Farsi weekday name. (utf8)
%G The full Farsi weekday name. (utf8)
%v The abbreviated Farsi month name. (utf8)
%V The full Farsi month name. (utf8)
%H The hour as a decimal number using a 24-hour clock (range 00 to 23).
%I The hour as a decimal number using a 12-hour clock (range 01 to 12).
%j The day of the year as a decimal number (range 001 to 366).
%k The hour (24-hour clock) as a decimal number (range 0 to 23); single digits are preceded by a
blank. (See also %H.) (TZ)
%l The hour (12-hour clock) as a decimal number (range 1 to 12); single digits are preceded by a
blank. (See also %I.) (TZ)
%m The month as a decimal number (range 01 to 12).
%M The minute as a decimal number (range 00 to 59).
%n A newline character. (SU)
%O AM or PM notation for the given time in Farsi equivalent. (utf8)
%p Either "AM" or "PM" according to the given time value. Noon is treated as "PM" and midnight as
"AM".
%P Like %p but in lowercase: "am" or "pm"
%r The time in a.m. or p.m. notation. In the POSIX locale this is equivalent to %I:%M:%S%p. (SU)
%R The time in 24-hour notation (%H:%M). (SU) For a version including the seconds, see %T below.
%s The number of seconds since the Epoch, 1970-01-01 (1348-10-11) 00:00:00 +0000 (UTC). (TZ)
%S The second as a decimal number (range 00 to 59).
%t A tab character. (SU)
%T The time in 24-hour notation (%H:%M:%S). (SU)
%u The day of the week as a decimal, range 1 to 7, Saturday being 1. See also %w. (SU)
%U The week number of the current year as a decimal number, range 00 to 53, starting with the first
Sunday as the first day of week 01.
%w The day of the week as a decimal, range 0 to 6, Saturday being 0. See also %u.
%W The preferred date in %Y/%m/%d format and Farsi. (utf8)
%x The preferred date representation without the time.
%X The preferred time representation without the date in Farsi. (utf8)
%y The year as a decimal number without a century (range 00 to 99).
%Y The year as a decimal number including the century.
%z The +hhmm or -hhmm numeric timezone (that is, the hour and minute offset from UTC). (SU)
%Z The timezone or name or abbreviation.
%% A literal '%' character.
The broken-down time structure tm is defined in <jtime.h>. See also jctime(3).