function FileSystemInterface::getTempDirectory

Same name in other branches
  1. 9 core/lib/Drupal/Core/File/FileSystemInterface.php \Drupal\Core\File\FileSystemInterface::getTempDirectory()
  2. 10 core/lib/Drupal/Core/File/FileSystemInterface.php \Drupal\Core\File\FileSystemInterface::getTempDirectory()
  3. 11.x core/lib/Drupal/Core/File/FileSystemInterface.php \Drupal\Core\File\FileSystemInterface::getTempDirectory()

Gets the path of the configured temporary directory.

If the path is not set, it will fall back to the OS-specific default if set, otherwise a directory under the public files directory. It will then set this as the configured directory.

Return value

string A string containing the path to the temporary directory.

1 method overrides FileSystemInterface::getTempDirectory()
FileSystem::getTempDirectory in core/lib/Drupal/Core/File/FileSystem.php
Gets the path of the configured temporary directory.

File

core/lib/Drupal/Core/File/FileSystemInterface.php, line 487

Class

FileSystemInterface
Provides an interface for helpers that operate on files and stream wrappers.

Namespace

Drupal\Core\File

Code

public function getTempDirectory();

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.