Php obtains the day of a day, the day of the week, and the date corresponding to the day of the week and the day of the week.
$ Today = date ("Y-m-d ");
Echo $ today; // you can get the number of today. Output
// Define an array first.
$
PHP retrieves the first and last days of the week. // The first and last days of the week. $ date = new & nbsp; DateTime (); $ date-& gt; modify ('This & nbsp; week '); $ first_day_of_week = $ date-& gt; format ('Y-m-D'); $ date-& gt; modify PHP get
Php gets the day of a day, the day of the week, and the date corresponding to the day of the week and the day of the week. Php returns the day of a day, the day of a week, and the date $ todaydate (Y-m-d) corresponding to Monday and next Monday.
PHP gets the first and last day of the week
The first and last day of the week$date =new DateTime ();$date->modify (' this week ');$first _day_of_week= $date->format (' y-m-d ');$date->modify (' This week +6 days ');$end _day_of_week= $date->format
PHP provides us with a large number of functions to get the day of the week, we commonly use the date () function, let me introduce the date of the week to get a specific instance.
PHP date () parameter description
Here the main use of the W this
Php returns the current date or the specified date is the day of the week. Php returns the current date or the specified date is the day of the week. php obtains the code for the current PHP day of the week: Copy the code as follows: date (l ); for
PHP to obtain the day of the Week program. In php, we want to obtain the day of the week, which can be operated by using the date function. next I will summarize the specific operation methods for you, I hope this method will be helpful to all of
PHP date () parameter descriptionThe w parameter is mainly used here. The explanation of this parameter is:W indicates the day of the week, and the number indicates 0 (Sunday) to 6 (Saturday)With this, it is very easy. The author directly posts the
I have been learning PHP for a long time. I would like to share my little experience with you here. PHP is a server scripting language used to create dynamic web pages. Like ASP and ColdFusion, users can use PHP and HTML to write WEB pages. When a
D & amp; nbsp; the day of the month, which has the 2nd digit from the leading zero, 01 to 31 & amp; nbsp; D & amp; nbsp; the day of the week, expressed in text, 3. Mon to the day of Sun & amp; nbsp; j & amp; nbsp; month
D. The day of the month,
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.