PHP frenchtojd()Function

PHP Calendar 参考手册PHP Calendar Reference Manual

Example

Convert a date in the French Republican calendar to a Julian Day Count, then convert it back to the French Republican calendar date:

<?php
$jd=frenchtojd(3,3,14);
echo $jd . "<br>";
echo jdtofrench($jd);
?>

Run example »

Definition and Usage

The frenchtojd() function converts a date in the French Republican calendar to a Julian Day Count.

Tip:The French Republican calendar is a calendar proposed during the French Revolution. The French government used it for about 12 years, starting in late 1793. This function only converts dates within years 1 to 14 (Gregorian dates September 22, 1792 - September 22, 1806).

Tip:See also jdtofrench()the function, which converts a Julian Day Count to a French Republican calendar date.

Syntax

frenchtojd(month,day,year);

Parameter Description
month Required. A number from 1 to 13, specifying the month.
day Required. A number from 1 to 30, specifying the day.
year Required. A number from 1 to 14, specifying the year.

Technical Details

Return Value: Returns the Julian Day number.
PHP Version: 4+


PHP Calendar 参考手册PHP Calendar Reference Manual Other Extensions