Difference between revisions of "NXSL:mktime"

288 bytes added ,  09:36, 17 April 2018
no edit summary
(Created page with "__NOTOC__ Converts broken down time (represented by object of TIME class) to UNIX time (number of seconds since epoch). TIME object can be returned...")
 
Line 19: Line 19:


UNIX time (number of seconds since epoch).
UNIX time (number of seconds since epoch).
== Example ==
<syntaxhighlight lang="c">
t = new TIME();  // create new TIME object
t->year = 2018;
t->mon = 3; // April (0-based month numbering)
t->mday = 10;
t->hour = 10;
t->min = 16;
t->sec = 55;
t->isdst = -1; // auto detect daylight saving
println mktime(t);
</syntaxhighlight>
683

edits