P
P
Pitman772017-08-21 10:46:17
JavaScript
Pitman77, 2017-08-21 10:46:17

Is there a script to convert Timestamp (UNIX) time to ISO 8601?

Hello!
I was puzzled by the micro-markup and ran into trouble - I can only receive the date and time of the news in the Timestamp format - 1503300202 or in the usual one - 08/21/2017, but neither one nor the other is suitable. I would like to give the date of the material for search engines in the format ISO 8601 - 2017-08-21T11:30:30+03:00

<meta itemprop="datePublished" content="$TIMESTAMP$">

To save myself from unnecessary manual work, I would like to fasten some light script that would translate $TIMESTAMP$ into ISO 8601 and substitute it into content="...". Is there something similar? If so, I'd be grateful for an example.
Thank you!

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question