PHP: time (), date (), mktime () date and time function libraries are often forgotten. here, you can add them to your favorites for convenience: checkdate: to verify the correctness of the date.
Date: format the server time.
Strftime: format the
PHP: time (), date (), mktime () date and time function libraries are often forgotten. here, you can add them to your favorites for convenience: checkdate: to verify the correctness of the date.
Date: format the server time.
Strftime: format the
Checkdate: Verify that the date is correct.Date: format the server time.Strftime: format the server time locally.Getdate: Get the time and date information.Gettimeofday: Get the current time.Gmdate: Get the current time difference from
PHP date/time functionDefinitions and usageThe Mktime () function returns a Unix timestamp for a date.
The parameter always represents the GMT date, so IS_DST has no effect on the result.
The parameters can be left-to-right, and the empty
PHP-time (), date (), mktime () date and time function library. Checkdate verifies the correctness of the date. Syntax: intcheckdate (intmonth, intday, intyear); return value: integer function type: time and date content description if the date is
Checkdate: Verify that the date is correct.
Date: format the server time.
Strftime: format the server time locally.
Getdate: Get the time and date information.
Gettimeofday: Get the current time.
Gmdate: Get the current time difference from
The following describes how to obtain the start time and end time of the current day. The code is as follows:Mktime (hour, minute, second, month, day, year, is_dst)Parameter descriptionHour is optional. The specified hour.Minute is optional. Minutes.
Checkdate: Verify the correctness of the date.
Date: Formats the time of the server.
Strftime: The time of the server is formatted locally.
GETDATE: Get time and date information.
Gettimeofday: Get the current time.
Gmdate: Gets the current time
The time () function returns the current date. The main function of the mktime () function is not to return the current time, but rather to format the time. Although writing mktime () alone does not add any parameters such as Echo mktime () and Echo
The time () function returns the current time. The main function of the mktime () function is not to return the current time, but to format the time () function to return the current time. The main function of the mktime () function is not to return
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.