PHP easter_date() Function
Complete PHP Calendar Reference
Definition and Usage
The easter_date() function returns the Unix timestamp for midnight on Easter of a
specified
year.
Syntax
| Parameter |
Description |
| year |
Optional. Defines the year to calculate the midnight on
Easter from. If the year parameter is omitted, the current year is used. |
Tips and Notes
Note: If the year is outside of the range for Unix timestamps (before
1970 or after 2037), this function will generate a warning. The easter_days()
function can be used instead of easter_date() to calculate Easter for years
which fall outside the range.
Example
<?php
echo(easter_date() . "<br />");
echo(date("M-d-Y",easter_date()) . "<br />");
echo(date("M-d-Y",easter_date(2000)) . "<br />");
echo(date("M-d-Y",easter_date(2001)) . "<br />");
echo(date("M-d-Y",easter_date(2002)));
?>
|
The output of the code above will be:
1145138400
Apr-16-2006
Apr-23-2000
Apr-15-2001
Mar-31-2002
|
Complete PHP Calendar Reference

Whether you're new to XML or already an advanced user,
the user-friendly views and powerful entry helpers,
wizards, and debuggers in XMLSpy are designed to meet your XML
and Web development needs from start to finish.
New features in Version 2010!
- XML editor
- Graphical XML Schema / DTD editors
- XSLT 1.0/2.0 editor, debugger, profiler
- XQuery editor, debugger, profiler
- XBRL validator, taxonomy editor, taxonomy wizard
- Support for Office Open XML (OOXML)
- Graphical WSDL 1.1/2.0 editor & SOAP debugger
- JSON editing & conversion
- Java, C#, C++ code generation
- And much more!
Download a free trial today!
|
|
|
|