I can not understand the error when formatting the date. Please tell me why in this code I get: 1970-01-01
strftime("%Y-%m-%d 00:00:00", date("Ym-01")) Instead of getting 2017-10-04 00:00:00
I can not understand the error when formatting the date. Please tell me why in this code I get: 1970-01-01
strftime("%Y-%m-%d 00:00:00", date("Ym-01")) Instead of getting 2017-10-04 00:00:00
Judging by the documentation, strftime looks like this:
string strftime ( string $format [, int $timestamp = time() ] ) This means that it is necessary to transfer not the date , but strtotime
Source: https://ru.stackoverflow.com/questions/726646/
All Articles
почему в таком коде я получаю: 1970-01-01- Becausestrftimetakesstrtotime, notdate, apparently - Alexei Shimansky