I in date in php is the capital form of i, indicating whether the date is in daylight saving time, if it is daylight saving time, it is 1, otherwise it is 0; while the lowercase i means "minute", with a leading Zero 00 to 59.

#The operating environment of this article: Windows7 system, PHP7.1, Dell G3 computer.
What does I mean in date in php?
date() function formats the local date and time and returns the formatted date string.
语法:date(format,timestamp);
The meaning of each letter in the PHP date date function
There are some characters with predefined meanings that you can use to create format strings. They are:
format 必需。规定输出日期字符串的格式。 可使用下列字符: d - 一个月中的第几天(从 01 到 31) D - 星期几的文本表示(用三个字母表示) j - 一个月中的第几天,不带前导零(1 到 31) l('L' 的小写形式)- 星期几的完整的文本表示 N - 星期几的 ISO-8601 数字格式表示(1表示Monday[星期一],7表示Sunday[星期日]) S - 一个月中的第几天的英语序数后缀(2 个字符:st、nd、rd 或 th。与 j 搭配使用) w - 星期几的数字表示(0 表示 Sunday[星期日],6 表示 Saturday[星期六]) z - 一年中的第几天(从 0 到 365) W - 用 ISO-8601 数字格式表示一年中的星期数字(每周从 Monday[星期一]开始) F - 月份的完整的文本表示(January[一月份] 到 December[十二月份]) m - 月份的数字表示(从 01 到 12) M - 月份的短文本表示(用三个字母表示) n - 月份的数字表示,不带前导零(1 到 12) t - 给定月份中包含的天数 L - 是否是闰年(如果是闰年则为 1,否则为 0) o - ISO-8601 标准下的年份数字 Y - 年份的四位数表示 y - 年份的两位数表示 a - 小写形式表示:am 或 pm A - 大写形式表示:AM 或 PM B - Swatch Internet Time(000 到 999) g - 12 小时制,不带前导零(1 到 12) G - 24 小时制,不带前导零(0 到 23) h - 12 小时制,带前导零(01 到 12) H - 24 小时制,带前导零(00 到 23) i - 分,带前导零(00 到 59) s - 秒,带前导零(00 到 59) u - 微秒(PHP 5.2.2 中新增的) e - 时区标识符(例如:UTC、GMT、Atlantic/Azores) I(i 的大写形式)- 日期是否是在夏令时(如果是夏令时则为 1,否则为 0) O - 格林威治时间(GMT)的差值,单位是小时(实例:+0100) P - 格林威治时间(GMT)的差值,单位是 hours:minutes(PHP 5.1.3 中新增的) T - 时区的简写(实例:EST、MDT) Z - 以秒为单位的时区偏移量。UTC 以西时区的偏移量为负数(-43200 到 50400) c - ISO-8601 标准的日期(例如 2013-05-05T16:34:42+00:00) r - RFC 2822 格式的日期(例如 Fri, 12 Apr 2013 12:01:05 +0200) U - 自 Unix 纪元(January 1 1970 00:00:00 GMT)以来经过的秒数 同时,也可使用下列预定义常量(从 PHP 5.1.0 开始可用): DATE_ATOM - Atom(例如:2013-04-12T15:52:01+00:00) DATE_COOKIE - HTTP Cookies(例如:Friday, 12-Apr-13 15:52:01 UTC) DATE_ISO8601 - ISO-8601(例如:2013-04-12T15:52:01+0000) DATE_RFC822 - RFC 822(例如:Fri, 12 Apr 13 15:52:01 +0000) DATE_RFC850 - RFC 850(例如:Friday, 12-Apr-13 15:52:01 UTC) DATE_RFC1036 - RFC 1036(例如:Fri, 12 Apr 13 15:52:01 +0000) DATE_RFC1123 - RFC 1123(例如:Fri, 12 Apr 2013 15:52:01 +0000) DATE_RFC2822 - RFC 2822(Fri, 12 Apr 2013 15:52:01 +0000) DATE_RFC3339 - 与 DATE_ATOM 相同(从 PHP 5.1.3 开始) DATE_RSS - RSS(Fri, 12 Aug 2013 15:52:01 +0000) DATE_W3C - 万维网联盟(例如:2013-04-12T15:52:01+00:00)
Recommended learning: "PHP Video Tutorial"
The above is the detailed content of What does I mean in date in php. For more information, please follow other related articles on the PHP Chinese website!
ACID vs BASE Database: Differences and when to use each.Mar 26, 2025 pm 04:19 PMThe article compares ACID and BASE database models, detailing their characteristics and appropriate use cases. ACID prioritizes data integrity and consistency, suitable for financial and e-commerce applications, while BASE focuses on availability and
PHP Secure File Uploads: Preventing file-related vulnerabilities.Mar 26, 2025 pm 04:18 PMThe article discusses securing PHP file uploads to prevent vulnerabilities like code injection. It focuses on file type validation, secure storage, and error handling to enhance application security.
PHP Input Validation: Best practices.Mar 26, 2025 pm 04:17 PMArticle discusses best practices for PHP input validation to enhance security, focusing on techniques like using built-in functions, whitelist approach, and server-side validation.
PHP API Rate Limiting: Implementation strategies.Mar 26, 2025 pm 04:16 PMThe article discusses strategies for implementing API rate limiting in PHP, including algorithms like Token Bucket and Leaky Bucket, and using libraries like symfony/rate-limiter. It also covers monitoring, dynamically adjusting rate limits, and hand
PHP Password Hashing: password_hash and password_verify.Mar 26, 2025 pm 04:15 PMThe article discusses the benefits of using password_hash and password_verify in PHP for securing passwords. The main argument is that these functions enhance password protection through automatic salt generation, strong hashing algorithms, and secur
OWASP Top 10 PHP: Describe and mitigate common vulnerabilities.Mar 26, 2025 pm 04:13 PMThe article discusses OWASP Top 10 vulnerabilities in PHP and mitigation strategies. Key issues include injection, broken authentication, and XSS, with recommended tools for monitoring and securing PHP applications.
PHP XSS Prevention: How to protect against XSS.Mar 26, 2025 pm 04:12 PMThe article discusses strategies to prevent XSS attacks in PHP, focusing on input sanitization, output encoding, and using security-enhancing libraries and frameworks.
PHP Interface vs Abstract Class: When to use each.Mar 26, 2025 pm 04:11 PMThe article discusses the use of interfaces and abstract classes in PHP, focusing on when to use each. Interfaces define a contract without implementation, suitable for unrelated classes and multiple inheritance. Abstract classes provide common funct


Hot AI Tools

Undresser.AI Undress
AI-powered app for creating realistic nude photos

AI Clothes Remover
Online AI tool for removing clothes from photos.

Undress AI Tool
Undress images for free

Clothoff.io
AI clothes remover

AI Hentai Generator
Generate AI Hentai for free.

Hot Article

Hot Tools

EditPlus Chinese cracked version
Small size, syntax highlighting, does not support code prompt function

WebStorm Mac version
Useful JavaScript development tools

Safe Exam Browser
Safe Exam Browser is a secure browser environment for taking online exams securely. This software turns any computer into a secure workstation. It controls access to any utility and prevents students from using unauthorized resources.

SublimeText3 English version
Recommended: Win version, supports code prompts!

Zend Studio 13.0.1
Powerful PHP integrated development environment






