[man]unset/man ? But if you want to do what laserlight said, then just use the common swap() function... e.g. in C++ you'd do:
template <class T> void swap ( T& a, T& b )
{
T c(a); a=b; b=c;
}
so just make the PHP equivalent:
function swap(&$a, &$b)
{
$c = $a; $a = $b; $b = $c;
}
and use it to swap elements in the array, e.g.:
swap($myArray[0], array_search(3160, $myArray)));