| @@ 3616-3623 (lines=8) @@ | ||
| 3613 | } |
|
| 3614 | ||
| 3615 | // $start |
|
| 3616 | if (is_array($start)) { |
|
| 3617 | $start = array_slice($start, 0, $num); |
|
| 3618 | foreach ($start as $key => $value) { |
|
| 3619 | $start[$key] = is_int($value) ? $value : 0; |
|
| 3620 | } |
|
| 3621 | } else { |
|
| 3622 | $start = array_pad(array($start), $num, $start); |
|
| 3623 | } |
|
| 3624 | ||
| 3625 | // $length |
|
| 3626 | if (!isset($length)) { |
|
| @@ 3628-3637 (lines=10) @@ | ||
| 3625 | // $length |
|
| 3626 | if (!isset($length)) { |
|
| 3627 | $length = array_fill(0, $num, 0); |
|
| 3628 | } elseif (is_array($length)) { |
|
| 3629 | $length = array_slice($length, 0, $num); |
|
| 3630 | foreach ($length as $key => $value) { |
|
| 3631 | if (isset($value)) { |
|
| 3632 | $length[$key] = (is_int($value) ? $value : $num); |
|
| 3633 | } else { |
|
| 3634 | $length[$key] = 0; |
|
| 3635 | } |
|
| 3636 | } |
|
| 3637 | } else { |
|
| 3638 | $length = array_pad(array($length), $num, $length); |
|
| 3639 | } |
|
| 3640 | ||