PHP jdmonthname() Function

In this chapter you will learn:

  1. Definition for PHP jdmonthname() Function
  2. Syntax for PHP jdmonthname() Function
  3. Parameter for PHP jdmonthname() Function
  4. Return value for PHP jdmonthname() Function
  5. Example for PHP jdmonthname() Function

Definition

The jdmonthname() function returns a month name.

Syntax

PHP jdmonthname() Function has the following syntax.

jdmonthname(jd,mode);

Parameter

ParameterIs RequiredDescription
jdRequired.A Julian Day number
modeOptional.Which calendar to convert the Julian Day Count to, and how the month name is to be returned.

Mode values:

ValueDescription
0 - Gregorianabbreviated form such as Jan, Feb, Mar, etc.
1 - Gregorianfull name form such as January, February, March, etc.
2 - Julianabbreviated form (Jan, Feb, Mar, etc.)
3 - Julianfull name form (January, February, March, etc.)
4 - JewishTishri, Heshvan, Kislev, etc.
5 - FrenchRepublican Vendemiaire, Brumaire, Frimaire, etc.

Return

PHP jdmonthname() Function returns the month name for the specified Julian Day and calendar.

Example

Return the abbreviated Gregorian monthname of 13th January, 2013:


<?php
$jd=gregoriantojd(1,13,2013);
echo jdmonthname($jd,0);
?>

The code above generates the following result.

Next chapter...

What you will learn in the next chapter:

  1. Definition for PHP jdtofrench() Function
  2. Syntax for PHP jdtofrench() Function
  3. Parameter for PHP jdtofrench() Function
  4. Return value for PHP jdtofrench() Function
  5. Example for PHP jdtofrench() Function
Home » PHP Tutorial » PHP Calendar Functions
PHP 5 Predefined Calendar Constants
PHP cal_days_in_month() Function
PHP cal_from_jd() Function
PHP cal_info() Function
PHP cal_to_jd() Function
PHP easter_date() Function
PHP easter_days() Function
PHP frenchtojd() Function
PHP gregoriantojd() Function
PHP jddayofweek() Function
PHP jdmonthname() Function
PHP jdtofrench() Function
PHP jdtogregorian() Function
PHP jdtojewish() Function
PHP jdtojulian() Function
PHP jdtounix() Function
PHP jewishtojd() Function
PHP juliantojd() Function
PHP unixtojd() Function