This question already has an answer here:
I am making a script in which I require views to displayed in today, yesterday, last month, this month. I was able to get views for today and yesterday using the following code:
$hour = 12;
$today_count = strtotime("$hour:00:00");
$yest_count = strtotime('-1 day', $today_count);
My timestamp in database is unix timestamp . How can i achieve to get this month and last month views?
</div>