drupal_clear_js_cache

Versions
6 – 7
drupal_clear_js_cache()

Delete all cached JS files.

▾ 2 functions call drupal_clear_js_cache()

drupal_flush_all_caches in includes/common.inc
Flush all cached data on the site.
system_modules_submit in modules/system/system.admin.inc
Submit callback; handles modules form submission.

Code

includes/common.inc, line 2415

<?php
function drupal_clear_js_cache() {
  file_scan_directory(file_create_path('js'), '.*', array('.', '..', 'CVS'), 'file_delete', TRUE);
  variable_set('javascript_parsed', array());
}
?>
Login or register to post comments
 
 

All source code and documentation on this site is released under the terms of the GNU General Public License, version 2 and later. Drupal is a registered trademark of Dries Buytaert.