Split date into parts - PHP/Laravel/Carbon
<p>I'm starting to integrate <code>carbon</code> into my website and can't seem to be able to get the format it wants.</p>

<pre><code>Carbon::create($year, $month, $day, $hour, $minute, $second, $tz);

// initial data
$day = 'today';
$time = '1100';

// i then convert them
$d = date('Y-m-d',strtotime($day));
$t = date('H:i:s',strtotime($time));

// this is what I end up with
date = "2016-01-05"
time":"11:00:00"
</code></pre>

<p>How can I split them with <code>php</code> to help me extract <code>$year, $month, $day, $hour, $minute, $second</code></p>