constant FILE_EXISTS_REPLACE

Flag for dealing with existing files: Replace the existing file.

Related topics

26 uses of FILE_EXISTS_REPLACE
CopyTest::testExistingReplace in drupal/core/modules/file/lib/Drupal/file/Tests/CopyTest.php
Test replacement when copying over a file that already exists.
DirectoryTest::testFileDestination in drupal/core/modules/system/lib/Drupal/system/Tests/File/DirectoryTest.php
This will test the filepath for a destination based on passed flags and whether or not the file exists.
drupal_build_css_cache in drupal/core/includes/common.inc
Aggregates and optimizes CSS files into a cache file in the files directory.
drupal_build_js_cache in drupal/core/includes/common.inc
Aggregates JavaScript files into a cache file in the files directory.
file_copy in drupal/core/modules/file/file.module
Copies a file to a new location and adds a file record to the database.

... See full list

File

drupal/core/includes/file.inc, line 124
API for handling file uploads and server file management.

Code

const FILE_EXISTS_REPLACE = 1;