What is Calendar cal from id in PHP

In this article I am going to explain about cal_from_id function in PHP.
  • 1858

PHP Calendar cal_from_jd() Function

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

Syntax of  cal_from_jd function

cal_from_jd(jd, calendar)

Parameters in cal_from_jd function

It have two parameters and all parameters is required.

Parameter Description
jd It is a Julian day as integer.
month It specifies calendar to use.

Example of Calendar cal_from_jd function

<html>

<body>

<?php

$today = unixtojd(mktime(0, 0, 0, 8, 20, 2012));

print_r(cal_from_jd($today, CAL_GREGORIAN));

 

?>

</body>

</html>


Output:

cal_from_jd function.jpg

You may also want to read these related articles :
here

Ask Your Question 

Got a programming related question? You may want to post your question here

Programming Answers here

Categories

More Articles

© 2020 DotNetHeaven. All rights reserved.