Difference between revisions of "Template:Format size"
Jump to navigation
Jump to search
(Support K) |
(no decimals above 64K) |
||
Line 1: | Line 1: | ||
<noinclude>'''This is for displaying a number of bytes in an easily understood format.'''<br/><br/> | <noinclude>'''This is for displaying a number of bytes in an easily understood format.'''<br/><br/> | ||
Usage:<br/> {{t|<nowiki>{{</nowiki>{{PAGENAME}}|#bytes<nowiki>}}</nowiki>}}</noinclude><includeonly>{{#ifexpr: | Usage:<br/> {{t|<nowiki>{{</nowiki>{{PAGENAME}}|#bytes<nowiki>}}</nowiki>}}</noinclude><includeonly>{{#ifexpr: | ||
− | {{{1}}} < 1024| {{{1}}} bytes| | + | {{{1}}} < 1024| {{{1}}} bytes|{{#ifexpr: |
− | {{#expr: {{{1}}}/1024 round 1}}K}}</includeonly> | + | {{{1}}} < 65535| {{#expr: {{{1}}}/1024 round 1}} K| |
+ | {{#expr: {{{1}}}/1024 round 0}} K}}}}</includeonly> |
Revision as of 12:43, 19 October 2014
This is for displaying a number of bytes in an easily understood format.
Usage:
{{Format size|#bytes}}