1$created = new Carbon($survey->created_at);
2$now = Carbon::now();
3$difference = ($created->diff($now)->days < 1)
4 ? 'today'
5 : $created->diffForHumans($now);
1$to = \Carbon\Carbon::createFromFormat('Y-m-d H:s:i', '2015-5-5 3:30:34');
2$from = \Carbon\Carbon::createFromFormat('Y-m-d H:s:i', '2016-6-6 9:30:34');
3$diff_in_months = $to->diffInMonths($from);
4print_r($diff_in_months); // Output: 1