From http://www.w3schools.com (Copyright Refsnes Data)
The array_pop() function deletes the last element of an array.
array_pop(array) |
Parameter | Description |
---|---|
array | Required. Specifies an array |
<?php $a=array("Dog","Cat","Horse"); array_pop($a); print_r($a); ?> |
The output of the code above will be:
Array ( [0] => Dog [1] => Cat ) |
From http://www.w3schools.com (Copyright Refsnes Data)