$site->files()

Returns a $files collection with all files placed directly in /content

  • return ($files)

Example

<h2>Files</h2>
<ul>
  <?php foreach($site->files() as $file): ?>
  <li>
    <a href="<?php echo $file->url() ?>">
      <?php echo $file->filename() ?>
      (<?php echo $file->niceSize() ?>)
    </a>
  </li>
  <?php endforeach ?>
</ul>