قالب:شهر/شرح

من أرابيكا، الموسوعة الحرة
اذهب إلى التنقل اذهب إلى البحث

This template returns the cyclic integer month number in ISO format (between 01 and 12) of the month whose real number is in parameter. Alternatively, the month can be given with its english name (complete or abbreviated to 3 characters, with capitals or small letters).

Syntax:
{{شهر|month}}
  • The month value is interpreted modulo 12 (extra leading zeroes are ignored, negative numbers are accepted, all numbers are rounded to floor).
Examples for all standard English month names:
{{شهر|january}} returns 01
{{شهر|february}} returns 02
{{شهر|march}} returns 03
{{شهر|april}} returns 04
{{شهر|may}} returns 05
{{شهر|june}} returns 06
{{شهر|july}} returns 07
{{شهر|august}} returns 08
{{شهر|september}} returns 09
{{شهر|october}} returns 10
{{شهر|november}} returns 11
{{شهر|december}} returns 12
Examples for all abbreviated English month names:
{{شهر|jan}} returns 01
{{شهر|feb}} returns 02
{{شهر|mar}} returns 03
{{شهر|apr}} returns 04
{{شهر|may}} returns 05
{{شهر|jun}} returns 06
{{شهر|jul}} returns 07
{{شهر|aug}} returns 08
{{شهر|sep}} returns 09
{{شهر|oct}} returns 10
{{شهر|nov}} returns 11
{{شهر|dec}} returns 12
Examples for all standard month numbers:
{{شهر|1}} returns 01
{{شهر|2}} returns 02
{{شهر|3}} returns 03
{{شهر|4}} returns 04
{{شهر|5}} returns 05
{{شهر|6}} returns 06
{{شهر|7}} returns 07
{{شهر|8}} returns 08
{{شهر|9}} returns 09
{{شهر|10}} returns 10
{{شهر|11}} returns 11
{{شهر|12}} returns 12
Examples for month numbers with extra leading zero:
{{شهر|01}} returns 01
{{شهر|02}} returns 02
{{شهر|03}} returns 03
{{شهر|04}} returns 04
{{شهر|05}} returns 05
{{شهر|06}} returns 06
{{شهر|07}} returns 07
{{شهر|08}} returns 08
{{شهر|09}} returns 09
Examples for month number underflows and overflows, from computed values:
{{شهر|-1200}} returns 12
{{شهر|-1201}} returns 11
{{شهر|-1212}} returns 12
{{شهر|-12}} returns 12
{{شهر|-11}} returns 01
{{شهر|-10}} returns 02
{{شهر|-9}} returns 03
{{شهر|-8}} returns 04
{{شهر|-7}} returns 05
{{شهر|-6}} returns 06
{{شهر|-5}} returns 07
{{شهر|-4}} returns 08
{{شهر|-3}} returns 09
{{شهر|-2}} returns 10
{{شهر|-1}} returns 11
{{شهر|-0.9999}} returns 11
{{شهر|-0.5}} returns 11
{{شهر|-0.0001}} returns 11
{{شهر|0}} returns 12
{{شهر|0.0001}} returns 12
{{شهر|0.5}} returns 12
{{شهر|0.9999}} returns 12
{{شهر|12.0001}} returns 12
{{شهر|12.5}} returns 12
{{شهر|12.9999}} returns 12
{{شهر|13}} returns 01
{{شهر|14}} returns 02
{{شهر|24}} returns 12
{{شهر|1200}} returns 12
{{شهر|1201}} returns 01
{{شهر|1212}} returns 12
Example for invalid month name:
{{شهر|xxx}} returns خطأ في التعبير: كلمة لم نتعرف عليها «xxx».
See also:
Template:MONTHNAME
قالب:MONTHABBREV
Template:MONTHNUMBER