You are here

public function FileSystemBase::directory in Forena Reports 8

Return the directory portion of a report filename.

Parameters

string $filename: relative path to file

Return value

string Name of directory containing the file.

File

src/File/FileSystemBase.php, line 236
FileSystemBase.inc File toolbox for manipulating files contained tn the report directory.

Class

FileSystemBase

Namespace

Drupal\forena\File

Code

public function directory($filename) {
  @(list($dir, $name_part) = explode('/', $filename, -1));
  return $this->dir . '/' . $dir;
}