function FileSystemInterface::delete
Same name in other branches
- 9 core/lib/Drupal/Core/File/FileSystemInterface.php \Drupal\Core\File\FileSystemInterface::delete()
- 8.9.x core/lib/Drupal/Core/File/FileSystemInterface.php \Drupal\Core\File\FileSystemInterface::delete()
- 11.x core/lib/Drupal/Core/File/FileSystemInterface.php \Drupal\Core\File\FileSystemInterface::delete()
Deletes a file without database changes or hook invocations.
This function should be used when the file to be deleted does not have an entry recorded in the files table.
Parameters
string $path: A string containing a file path or (streamwrapper) URI.
Throws
\Drupal\Core\File\Exception\FileException Implementation may throw FileException or its subtype on failure.
File
-
core/
lib/ Drupal/ Core/ File/ FileSystemInterface.php, line 309
Class
- FileSystemInterface
- Provides an interface for helpers that operate on files and stream wrappers.
Namespace
Drupal\Core\FileCode
public function delete($path);
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.