script_concat_settings

Determine the concatenation and compression settings for scripts and styles.

Description

script_concat_settings(); 

Usage

  1. if ( !function_exists( 'script_concat_settings' ) ) { 
  2. require_once ABSPATH . WPINC . '/script-loader.php'; 
  3.  
  4.  
  5. // NOTICE! Understand what this does before running. 
  6. $result = script_concat_settings(); 
  7.  

Defined (1)

The function is defined in the following location(s).

/wp-includes/script-loader.php  
  1. function script_concat_settings() { 
  2. global $concatenate_scripts, $compress_scripts, $compress_css; 
  3.  
  4. $compressed_output = ( ini_get('zlib.output_compression') || 'ob_gzhandler' == ini_get('output_handler') ); 
  5.  
  6. if ( ! isset($concatenate_scripts) ) { 
  7. $concatenate_scripts = defined('CONCATENATE_SCRIPTS') ? CONCATENATE_SCRIPTS : true; 
  8. if ( ( ! is_admin() && ! did_action( 'login_init' ) ) || ( defined('SCRIPT_DEBUG') && SCRIPT_DEBUG ) ) 
  9. $concatenate_scripts = false; 
  10.  
  11. if ( ! isset($compress_scripts) ) { 
  12. $compress_scripts = defined('COMPRESS_SCRIPTS') ? COMPRESS_SCRIPTS : true; 
  13. if ( $compress_scripts && ( ! get_site_option('can_compress_scripts') || $compressed_output ) ) 
  14. $compress_scripts = false; 
  15.  
  16. if ( ! isset($compress_css) ) { 
  17. $compress_css = defined('COMPRESS_CSS') ? COMPRESS_CSS : true; 
  18. if ( $compress_css && ( ! get_site_option('can_compress_scripts') || $compressed_output ) ) 
  19. $compress_css = false;