rest_get_date_with_gmt()
rest_get_date_with_gmt( string $date, bool $is_utc = fa…
rest_get_date_with_gmt( string $date,  bool $is_utc = false )
以MySQL datetime格式将日期解析为其本地和UTC等效值。
Parses a date into both its local and UTC equivalent, in MySQL datetime format.
以MySQL datetime格式将日期解析为其本地和UTC等效值。
Parses a date into both its local and UTC equivalent, in MySQL datetime format.
目录锚点:#说明#参数#返回#源码
说明(Description)
另见函数 rest_parse_date()
参数(Parameters)
| 参数 | 类型 | 必填 | 说明 | 
|---|---|---|---|
| $date | (string) | 必需 | RFC3339时间戳。 | 
| $is_utc | (bool) | 可选 | 提供的日期是否应解释为UTC。 | 
返回(Return)
(array|null)本地和UTC日期时间string,采用MySQL日期时间格式(array|null),失败时为空。
源码(Source)
| 更新版本 | 源码位置 | 使用 | 被使用 | 
|---|---|---|---|
| 4.4.0 | wp-includes/rest-api.php:985 | 2 | 3 | 
类别:WordPress 函数手册、 
		本文收集自互联网,转载请注明来源。
如有侵权,请联系 wper_net@163.com 删除。



还没有任何评论,赶紧来占个楼吧!