get_recent_items — Get the most recently added items.

Item-related functions

Summary

get_recent_items($num = 10)

Get the most recently added items.

Parameters:
  • $num (int) – The maximum number of recent items to return

Returns:

array

Usage

Examples

Use the $num parameter to set the number of recent items to display. Default is 10 items. Often used with set_loop_records.

<?php set_loop_records('items', get_recent_items(5)); ?>

See Also