Alternative way to splice PHP array