The JDDayOfWeek() function returns the day of a week.
Syntax
jddayofweek(julian_day, mode)
Parameters
julian_day − A julian day number.
mode − Specify the week modes. Possible values:
0 - Default. Returns the weekday as an integer (0=Sunday, 1=Monday, etc.)
1 - Returns the weekday as a string (Sunday, Monday, etc.)
2 - Returns the weekday as a string, abbreviated form (Sun, Mon, Tue, etc.)
Return
The JDDayOfWeek() function returns the day of the week as a string or integer.
Example
The following is an example −
<?php $res = gregoriantojd(5,8,2018); echo jddayofweek($res,1); ?>
Output
The following is the output −
Tuesday