$file->next()

Returns the next sibling

  • return ($file)

Example

if($next = $page->file('myfile.pdf')->next()) {
  echo 'Next file: ' . $next->filename();
}

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