Get the first & last elements of an associative array
This is a small tutorial on how to get the first elements of an associative array in PHP. As you probably already know, associative arrays are extremely popular in PHP, simply because they allow you to set keys/indexes that are human-friendly! Unfortunately, one of the drawbacks to using an associative array is that it can…