Template:Time: Difference between revisions

No edit summary
(Use module instead of template. Template would become too verbose to get the same functionality as the module)
 
(9 intermediate revisions by 3 users not shown)
Line 1: Line 1:
Takes in a number of seconds and converts it into "X days, X hours, X minutes, X seconds"
<onlyinclude><includeonly>{{#invoke:Time|secondsToHuman|{{{1|}}}}}</includeonly></onlyinclude><noinclude>{{/doc}}</noinclude>
For example, {{T|Time|90135}} becomes {{Time|90135}}, {{T|Time|90135|hms=True}} becomes {{Time|90135|hms=True}}.
 
This uses a function inside of [[Module:Common]].<onlyinclude><includeonly>{{#invoke:common|prettyPrintTime|{{{1}}}|hms={{{hms}}}}}</includeonly></onlyinclude>

Latest revision as of 20:53, 13 April 2024

Takes in a number of seconds and converts it into "X days, X hours, X minutes, X seconds" For example, {{Time|900135}} becomes 10 days, 10 hours, 2 minutes, 15.00 seconds