$page->hasArchives()

Checks if there are any archive files (zip, gzip, tar) in the page's directory

  • return (integer)

Example

<?php
echo $page->hasArchives(); //returns the number of archive files in the folder

if($page->hasArchives()) {
  $archives = $page->archives();
}
?>

Is something missing or incorrect? Edit this page on Github…