Bug #76926 [Fbk]: The date constant format is different. DATE_RFC1123 

From: Date: Wed, 26 Sep 2018 01:28:35 +0000
Subject: Bug #76926 [Fbk]: The date constant format is different. DATE_RFC1123 
References: 1  Groups: php.doc.bugs 
Request: Send a blank email to doc-bugs+get-16022@lists.php.net to get a copy of this message
Edit report at https://bugs.php.net/bug.php?id=76926&edit=1 ID: 76926 Updated by: requinix@php.net Reported by: no-reply at example dot com Summary: The date constant format is different. DATE_RFC1123  Status: Feedback Type: Bug Package: Documentation problem PHP Version: 7.3.0RC1 Block user comment: N Private report: N New Comment: If you aren't comfortable writing English then use your native language. Either way, speak, don't link. Previous Comments: ------------------------------------------------------------------------ [2018-09-26 01:25:05] no-reply at example dot com https://docs.oracle.com/javase/8/docs/api/java/time/format/DateTimeFormatter.html#RFC_1123_DATE_TIME https://stackoverflow.com/questions/25658897/is-utc-a-valid-timezone-name-for-rfc-1123-specification ------------------------------------------------------------------------ [2018-09-26 01:16:57] requinix@php.net And? Use your words. Full sentences. ------------------------------------------------------------------------ [2018-09-26 01:15:17] no-reply at example dot com <!DOCTYPE html> <html><head><meta charset="UTF-8"></head> <body><script> alert('RFC-1123 formatted date stamp is ' + (new Date).toUTCString()) </script> </html> ------------------------------------------------------------------------ [2018-09-26 01:02:37] no-reply at example dot com https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toUTCString dateObj.toUTCString() The most common return value was an RFC-1123 formatted date stamp ------------------------------------------------------------------------ [2018-09-24 02:29:14] requinix@php.net You know we aren't Microsoft, right? The actual RFC 1123 says > There is a strong trend towards the use of numeric timezone > indicators, and implementations SHOULD use numeric timezones > instead of timezone names. https://tools.ietf.org/html/rfc1123 And the standard there is basically just a slight adjustment to RFC 822's which describes the timezone as > zone = ... / ( ("+" / "-") 4DIGIT ) ; Local differential hours+min. (HHMM) https://tools.ietf.org/html/rfc822 And the actual output from PHP matches what the documentation describes. So I don't know what bug you're reporting. If anything it's .NET that's difficult because the format string clearly outputs "GMT" as the timezone, which is alluded to in the general date/time formatting docs: > Although the RFC 1123 standard expresses a time as Coordinated Universal Time (UTC), the > formatting operation > does not modify the value of the DateTime object that is being formatted. Therefore, you must > convert the > DateTime value to UTC by calling the DateTime.ToUniversalTime method before you perform the > formatting > operation. https://docs.microsoft.com/en-us/dotnet/standard/base-types/standard-date-and-time-format-strings#RFC1123 ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=76926 -- Edit this bug report at https://bugs.php.net/bug.php?id=76926&edit=1

« previous php.doc.bugs (#16022) next »