You are here

function _boost_copy_file in Boost 6

Copy a file.

Parameters

$src: Source File.

$dest: Destination.

2 calls to _boost_copy_file()
_boost_copy_css_files in ./boost.module
Extract css filenames from html and copy them & their children.
_boost_copy_js_files in ./boost.module
Extract javascript filenames from html and copy them & their children.

File

./boost.module, line 4986
Provides static file caching for Drupal text output. Pages, Feeds, ect...

Code

function _boost_copy_file($src, $dest) {
  $destinations = _boost_copy_file_get_domains($dest);
  foreach ($destinations as $destination) {
    if (_boost_mkdir_p(dirname($destination))) {
      @copy($src, $destination);
      if (is_numeric(BOOST_PERMISSIONS_FILE)) {
        @chmod($destination, octdec(BOOST_PERMISSIONS_FILE));
      }
    }
  }
}