top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

How to get first item or last item from the collection?

0 votes
123 views
How to get first item or last item from the collection?
posted Aug 22, 2014 by Rajneesh

Share this question
Facebook Share Button Twitter Share Button LinkedIn Share Button

1 Answer

0 votes

You write this code for get first item or last item from the collection.

$collection->getFirstItem() and $collection->getLastItem();
answer Aug 24, 2014 by Vrije Mani Upadhyay
...