Web | This Site

Learning PHP
Advanced PHP
PHP Function Reference
PHP Useful Resources
Selected Reading
© 2011 TutorialsPoint.COM

| Home |  | References |  | Discussion Forums |  | About TP

# PHP Function easter_date()

## Syntax

easter_date ( [$year] );

## Definition and Usage

This function returns the Unix timestamp corresponding to midnight on Easter of the given year.

## Paramters

Parameter | Description
--- | ---
year | Optional. The year as a number between 1970 an 2037

## Return Value

Unix timestamp corresponding to midnight on Easter of the given year.

## Example

Try out following example:

    <?php
    echo date("M-d-Y", easter_date(2019));
    echo "<br />";
    echo date("M-d-Y", easter_date(2010));
    echo "<br />";
    echo date("M-d-Y", easter_date(2007));
    ?>

This will produce following result:

    Apr-21-2019
    Apr-04-2010
    Apr-08-2007

Advertisement

Online Image Processing

Indian Baby Names