Learning PHP
Advanced PHP
PHP Function Reference
PHP Useful Resources
Selected Reading
© 2011 TutorialsPoint.COM
|
PHP Function jdmonthname()
Syntax
jdmonthname ( $julianday [, $mode] );
|
Definition and Usage
This function returns a string containing a month name. mode tells this function which calendar to convert the Julian Day Count to, and what type of month names are to be returned.
Paramters
Parameter | Description |
julianday | Required. The Julian Day to operate on |
mode | Optional. Defines which calendar to convert the Julian day count to, and what type of month names are to be returned. Mode values:
- 0 - Gregorian - abbreviated (Jan, Feb, Mar, etc.)
- 1 - Gregorian (January, February, March, etc.)
- 2 - Julian - abbreviated (Jan, Feb, Mar, etc.)
- 3 - Julian (January, February, March, etc.)
- 4 - Jewish (Tishri, Heshvan, Kislev, etc.)
- 5 - French Republican (Vendemiaire, Brumaire, Frimaire, etc.)
|
Return Value
The month name for the given Julian Day and calendar.
Example
Try out following example:
<?php
$jd=cal_to_jd(CAL_GREGORIAN,date("m"),date("d"),date("Y"));
echo(jdmonthname($jd,1));
?>
|
This will produce following result:
|
|
|