M
M
Maxim Timofeev2014-12-17 00:18:14
Yii
Maxim Timofeev, 2014-12-17 00:18:14

How to use date formatter in yii2?

What if you use this code?

Yii::$app->formatter->asDate($this->stop, 'd MMMM yyyy');

I receive:
January 31, 1992
Attention question!!! How to get unix timestamp from January 31, 1992?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
K
krypt3r, 2014-12-17
@webinar

Yii::$app->formatter->asTimestamp ($this->stop);

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question