Given this PHP for
loop
$row->frequency = 1;
$row->date_1 = 10000;
$row->interval = 86400;
for ($i = 0; $i <= $row->frequency; $i++) {
$cal_data[] = array(
'start' => strtotime($row->date_1) + $row->interval,
);
}
I would like the first iteration of the loop to ignore the + $row->interval
giving me as a result:
10000
96400
I've seen this done with modulus but couldn't manage to make it work here. Anyone have suggestions?
Thanks!