xPDOCacheManager.copyTree
Last updated Apr 6th, 2019 | Page history | Improve this page | Report an issue
Support the team building MODX with a monthly donation.
The budget raised through OpenCollective is transparent, including payouts, and any contributor can apply to be paid for their work on MODX.
Backers
Budget
$306 per month—let's make that $500!
Learn morexPDOCacheManager::copyTree¶
Recursively copies a directory tree from a source directory to a target directory. Allows the following options:
-
new_dir_permissions
- The permissions to set any new directories to that were created in the target. (Can also be the 4th parameter of copyFile.) Defaults to 0775. -
new_file_permissions
- The permissions to set the new file to ifcopy_preserve_permissions
is false. Defaults to 0664. -
copy_exclude_items
- An array of names of files to skip. -
copy_exclude_patterns
- An array or string of patterns to exclude by.
Syntax¶
API Docs: http://api.modxcms.com/xpdo/cache/xPDOCacheManager.html#copyTree
array|boolean copyTree (string $source, string $target, [array $options = array()])
Example¶
Copy a directory:
$xpdo->cacheManager->copyTree('/my/old/dir/','/my/new/dir/');
See Also¶
- xPDOCacheManager.copyFile
- xPDOCacheManager.copyTree
- xPDOCacheManager.delete
- xPDOCacheManager.deleteTree
- xPDOCacheManager.endsWith
- xPDOCacheManager.escapeSingleQuotes
- xPDOCacheManager.get
- xPDOCacheManager.getCachePath
- xPDOCacheManager.getCacheProvider
- xPDOCacheManager.matches
- xPDOCacheManager.replace
- xPDOCacheManager.writeFile
- xPDOCacheManager.set
- xPDOCacheManager.writeTree
- xPDOCacheManager
Support the team building MODX with a monthly donation.
The budget raised through OpenCollective is transparent, including payouts, and any contributor can apply to be paid for their work on MODX.
Backers
Budget
$306 per month—let's make that $500!
Learn more