title: Laravel Get created_at in Millisecond Timestamp
body: <p>In Laravel 5.1, I am trying to get the <code>created_at</code> date in millisecond timestamp to use in frontend javascript. How can I do that? My query at the moment is something like this:</p>
  
  <pre><code>$stats = User::where('created_at', '&gt;=', $range)
                 -&gt;groupBy('date')
                 -&gt;orderBy('date', 'DESC')
                 -&gt;get([
                        DB::raw('Date(created_at) as date'),
                        DB::raw('COUNT(*) as value')
                      ])
                 -&gt;toJSON();
  </code></pre>
  
  <p>I want the output of <code>created_at</code> to be like this: <code>1325356200000</code></p>