PHP » GoLang |
login |
register |
about
|
array_slice(PHP 4, PHP 5, PHP 7) array_slice — Extract a slice of the array Description
array array_slice
( array
$array
, int $offset
[, int $length = NULL
[, bool $preserve_keys = FALSE
]] )
array_slice() returns the sequence of elements
from the array Parameters
Return ValuesReturns the slice. If the offset is larger than the size of the array then returns an empty array. Changelog
Examples
Example #1 array_slice() examples
<?php The above example will output: Array ( [0] => c [1] => d ) Array ( [2] => c [3] => d ) See Also
|
more
Recently updated
more
Most requested
more
Last requests
|