$files->pluck($field, $split = null, $unique = false)

Plucks all values for a specific field from the collection and returns those as array.

  • return (array)

Example

<ul>
  <?php foreach($page->files()->pluck('filename') as $filename): ?>
  <li><?= html($filename) ?></li>
  <?php endforeach ?>
</ul>