How to get second last array in php?
lets take an example
like this is your array
Array
(
[0] => 14802 Stony Plain Rd NW
[1] => Edmonton
[2] => AB T5N 3S5
)
and you want to get second last array "
Edmonton"
then simple use this array like this
end($array);
$z = prev($array);
this is effective and you can get second last array.
:)
Comments
Post a Comment