You are here

function advagg_get_info_on_file in Advanced CSS/JS Aggregation 7.2

Given a filename calculate various hashes and gather meta data.


  'filesize' => filesize($filename),
  'mtime' => @filemtime($filename),
  'filename_hash' => $filename_hash,
  'content_hash' => drupal_hash_base64($file_contents),
  'linecount' => $linecount,
  'data' => $filename,
  'fileext' => $ext,

Parameters

string $filename: String; filename containing path information.

bool $bypass_cache: (optional) Bool: TRUE to bypass the cache.

bool $run_alter: (optional) Bool: FALSE to not run drupal_alter.

Return value

array Array containing key value pairs.

14 calls to advagg_get_info_on_file()
advagg_admin_get_file_info in ./advagg.admin.inc
Get detailed info about the given filename.
advagg_create_subfile in ./advagg.inc
Write CSS parts to disk; used when CSS selectors in one file is > 4096.
advagg_css_alter in advagg_font/advagg_font.module
Implements hook_css_alter().
advagg_detect_subfile_changes in ./advagg.cache.inc
See if any of the subfiles has changed.
advagg_js_compress_advagg_get_js_file_contents_alter in advagg_js_compress/advagg_js_compress.advagg.inc
Implements hook_advagg_get_js_file_contents_alter().

... See full list

4 string references to 'advagg_get_info_on_file'
advagg_detect_subfile_changes in ./advagg.cache.inc
See if any of the subfiles has changed.
advagg_js_compress_advagg_get_info_on_files_alter in advagg_js_compress/advagg_js_compress.advagg.inc
Implements hook_advagg_get_info_on_files_alter().
advagg_load_files_info_into_static_cache in ./advagg.inc
Load cache bin file info in static cache.
advagg_push_new_changes in ./advagg.cache.inc
Flush the correct caches so CSS/JS changes go live.

File

./advagg.inc, line 750
Advanced CSS/JS aggregation module.

Code

function advagg_get_info_on_file($filename, $bypass_cache = FALSE, $run_alter = TRUE) {
  $files_info = advagg_get_info_on_files(array(
    $filename,
  ), $bypass_cache, $run_alter);
  return $files_info[$filename];
}