array_slice, extracts a range of elements out of the target array based upon the parameters that you give it.
- The array from which to remove the range of elements.
- Specifies the element index (by the array pointer) where to start the slice If the offset is negative, it starts at the element from the end of the array; else the offset starts from index zero to where it is specified.
- optional Specify how many elements you want.
- optional When set to
TRUE, the array’s keys will be preserved; else, the keys will be reindexed and re-ordered.
Returns a new array with the range of elements you specified.
Code. Eat. Code. Sleep. Dream about Code. Code.
More coming soon…keep checking back.