What is Calendar easter date in PHP

In this article I am going to explain about easter date function in PHP.
  • 1896

PHP Calendar easter_date() Function

The calendar easter_date function returns the Unix timestamp for midnight on Easter of a given year.

Syntax of  easter_date function

easter_date(year)

Parameters in easter_date  function

It has only one parameter:

Parameter Description
year The year as a number between 1970 an 2037, if you are not using year parameter, the current year is used.

Example of Calendar easter_date function

<html>

<body>

<?php

echo date("M-d-Y", easter_date());       

echo "<br />";

echo date("M-d-Y", easter_date(2015));       

echo "<br />";

echo date("M-d-Y", easter_date(2010));       

echo "<br />";

echo date("M-d-Y", easter_date(2005));

?>

</body>

</html>

 

Output:

easter_date 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

© 2019 DotNetHeaven. All rights reserved.