| @@ 3606-3613 (lines=8) @@ | ||
| 3603 | } |
|
| 3604 | ||
| 3605 | // $start |
|
| 3606 | if (is_array($start)) { |
|
| 3607 | $start = array_slice($start, 0, $num); |
|
| 3608 | foreach ($start as $key => $value) { |
|
| 3609 | $start[$key] = is_int($value) ? $value : 0; |
|
| 3610 | } |
|
| 3611 | } else { |
|
| 3612 | $start = array_pad(array($start), $num, $start); |
|
| 3613 | } |
|
| 3614 | ||
| 3615 | // $length |
|
| 3616 | if (!isset($length)) { |
|
| @@ 3618-3627 (lines=10) @@ | ||
| 3615 | // $length |
|
| 3616 | if (!isset($length)) { |
|
| 3617 | $length = array_fill(0, $num, 0); |
|
| 3618 | } elseif (is_array($length)) { |
|
| 3619 | $length = array_slice($length, 0, $num); |
|
| 3620 | foreach ($length as $key => $value) { |
|
| 3621 | if (isset($value)) { |
|
| 3622 | $length[$key] = (is_int($value) ? $value : $num); |
|
| 3623 | } else { |
|
| 3624 | $length[$key] = 0; |
|
| 3625 | } |
|
| 3626 | } |
|
| 3627 | } else { |
|
| 3628 | $length = array_pad(array($length), $num, $length); |
|
| 3629 | } |
|
| 3630 | ||