jd

How to Convert Julian Day into a Specified Calendar in PHP

PHP cal_from_jd()

The cal_from_jd() function converts the specified Julian day into a date of the specified calendar.

Syntax of this function:

cal_from_jd(jd,calendar) jd - A number (a Julian day count). (required) calendar - specifies the calendar to use. (required) The following calendar values can be used:
  • CAL_GREGORIAN
  • CAL_JULIAN
  • CAL_JEWISH
  • CAL_FRENCH