PHP
HTML
CSS
JavaScript
jQuery
SQL
WordPress
PHP Reference

Quick Reference

The PHP jddayofweek() function returns the day of the week.

				
					<?php
$jd = gregoriantojd(9, 5, 2023);
echo jddayofweek($jd, 1);
?>
				
			

Output

				
					Tuesday
				
			

Syntax

				
					jddayofweek(jd, mode)
				
			

Parameters

ParameterDescription
jdA Julian Day number (required)
modeSpecifies how to return the weekday:

  • 0 - Returns the weekday as an integer (0=Sunday, 1=Monday, etc.) (default)

  • 1 - Returns the weekday as a string (Sunday, Monday, etc.)

  • 2 - Returns the weekday as a string, abbreviated form (Sun, Mon, etc.)

We’d like to acknowledge that we learned a great deal of our coding from W3Schools and TutorialsPoint, borrowing heavily from their teaching process and excellent code examples. We highly recommend both sites to deepen your experience, and further your coding journey. We’re just hitting the basics here at 1SMARTchicken.

PHP
HTML
CSS
JavaScript
jQuery
SQL
WordPress

Why 1SMARTchicken?

This site was built and is maintained to benefit my autistic son.
See More →

My Son's Name is Johnny

He was diagnosed as autistic quite late, at age four...
His story

Buy Me a Coffee

Thanks for your support!

Feedback

If you see an error on the page or the code itself is incorrect or incomplete, or just plain wrong, please let us know. We’re always learning. NOTE: we do not sell your information and will not send you spam emails.