Array_unshift like function that returns the array
arrays, php
Solution
You could use
array_merge()
For example
$resultingArray = array_merge(array($newElement), $originalArray);
Problem
is there a built in function in php that prepends an element to an array, and returns the new array? instead of returning the new length of the array?