Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Доработать функцию ДатаИзСтрокиRFC7231 #150

Open
nec1ron opened this issue Oct 16, 2024 · 5 comments
Open

Доработать функцию ДатаИзСтрокиRFC7231 #150

nec1ron opened this issue Oct 16, 2024 · 5 comments

Comments

@nec1ron
Copy link

nec1ron commented Oct 16, 2024

не возращается дата, если год указан из 2 последних чисел

ДатаИзСтрокиRFC7231("Wed 16-Oct-24 07:36:30 GMT")
// 01.01.0001 0:00:00 Дата

ДатаИзСтрокиRFC7231("Wed 16-Oct-2024 07:36:30 GMT")
//16.10.2024 7:36:30 Дата

@leemuar
Copy link
Collaborator

leemuar commented Oct 16, 2024

Стандарт, на который стоит опираться при доработке:
https://www.rfc-editor.org/rfc/rfc7231#section-7.1.1.1
https://www.rfc-editor.org/rfc/rfc2616#section-3.3

@leemuar
Copy link
Collaborator

leemuar commented Nov 18, 2024

@nec1ron а какой сервис вам отает дату в таком "некорректном" формате?

@nec1ron
Copy link
Author

nec1ron commented Nov 26, 2024

@leemuar самый просто пример https://www.google.com/

set-cookie:
SIDCC=AKEyXzWRGTTwFemZshMbgpLER4joqvkdD5QfH8mo5OBKiw_P3yHlYDypK7FutNrX3bQ8xG83ZKI; expires=Wed, 26-Nov-2025 05:39:33 GMT; path=/; domain=.google.com; priority=high

@leemuar
Copy link
Collaborator

leemuar commented Nov 26, 2024

Но здесь же дата из 4 цифр состоит?

@leemuar самый просто пример https://www.google.com/

set-cookie: SIDCC=AKEyXzWRGTTwFemZshMbgpLER4joqvkdD5QfH8mo5OBKiw_P3yHlYDypK7FutNrX3bQ8xG83ZKI; expires=Wed, 26-Nov-2025 05:39:33 GMT; path=/; domain=.google.com; priority=high

@nec1ron
Copy link
Author

nec1ron commented Nov 26, 2024

@leemuar виноват, вот пример https://ru.stackoverflow.com/

set-cookie:
__cflb=0H28vawedh7dVaNLPHv8dMdmakdmg6mCCe733VpUhQ8; SameSite=Lax; path=/; expires=Wed, 27-Nov-24 07:15:16 GMT; HttpOnly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants