PHP JDDayOfWeek() Function
Complete PHP Calendar Reference
Definition and Usage
The JDDayOfWeek() function returns the day of a week.
Syntax
| Parameter |
Description |
| jd |
Required. A number (a Julian day count) |
| mode |
Optional. Defines what to return (integer or string). Mode
values:
- 0 - Default. Returns the day number as an int (0=Sunday, 1=Monday,
etc)
- 1 - Returns a string that contains the day of week
(English-Gregorian)
- 2 - Returns a string that contains the abbreviated day of week
(English-Gregorian)
|
Example
<?php
$jd=cal_to_jd(CAL_GREGORIAN,date("m"),date("d"),date("Y"));
echo(jddayofweek($jd,1));
?>
|
The output of the code above could be:
Complete PHP Calendar Reference
 |
W3Schools' Online Certification Program
The perfect solution for professionals who need to balance work, family, and career building.
More than 4000 certificates already issued!
|
The HTML Certificate documents your knowledge of HTML, XHTML, and CSS.
The JavaScript Certificate documents your knowledge of JavaScript and HTML DOM.
The XML Certificate documents your knowledge of XML, XML DOM and XSLT.
The ASP Certificate documents your knowledge of ASP, SQL, and ADO.
The PHP Certificate documents your knowledge of PHP and SQL (MySQL).
|