Add Date.toW3CString method to the Date class.
The method return a date string in the W3C date time format: yyyy-mm-ddThh:ii:ss+zz:zz.
| Method / Format | Result |
|---|---|
Date.toGMTString() |
Sat, 21 Nov 2015 08:27:38 GMT |
Date.toUTCString() |
Sat, 21 Nov 2015 08:27:38 GMT |
Date.toISOString() |
2015-11-21T08:27:38.567Z |
Date.toW3CString() |
2015-11-21T09:27:38+01:00 |