? boost-602098.patch
? boost-602102_0.patch
? boost-604390.patch
? boost-605222.patch
? boost-607112.patch
Index: boost.admin.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/boost/boost.admin.inc,v
retrieving revision 1.1.2.1.2.3.2.90
diff -u -p -r1.1.2.1.2.3.2.90 boost.admin.inc
--- boost.admin.inc	18 Oct 2009 08:17:51 -0000	1.1.2.1.2.3.2.90
+++ boost.admin.inc	18 Oct 2009 08:30:35 -0000
@@ -83,7 +83,7 @@ function boost_admin_boost_performance_p
   $form['boost']['boost_enabled'] = array(
     '#type'          => 'radios',
     '#title'         => t('Boost - Static page cache'),
-    '#default_value' => variable_get('boost_enabled', CACHE_DISABLED),
+    '#default_value' => BOOST_ENABLED,
     '#options'       => array(
       CACHE_DISABLED => t('Disabled'),
       CACHE_NORMAL => t('Enabled'),
@@ -482,7 +482,7 @@ function boost_admin_boost_performance_p
   $form['advanced']['boost_ignore_flush'] = array(
     '#type'          => 'radios',
     '#title'         => t('Ignore cache flushing'),
-    '#default_value' => variable_get('boost_ignore_flush', 0),
+    '#default_value' => variable_get('boost_ignore_flush', 1),
     '#options'       => array(
       0 => t('Disabled'),
       1 => t('Only Ignore Clear Entire Cache Commands (Recommended if caching css/js files)'),
@@ -513,32 +513,68 @@ function boost_admin_boost_performance_p
     '#default_value' => BOOST_CRAWL_ON_CRON,
     '#description'   => t('Pre-cache boosted URL\'s so they get cached before anyone accesses them. Enable the crawler first and save settings to use Preemptive Cache settings.'),
   );
+  if (BOOST_CRAWL_ON_CRON && BOOST_OVERWRITE_FILE) {
+    $description = t('Bypass cron cache expiration and load to be expired content in the crawler. Allow this servers IP to bypass the boost cache. Check for fast but potentially stale; uncheck for slow but always fresh.');
+  }
+  elseif(!BOOST_CRAWL_ON_CRON) {
+    $description = t('Enable the crawler first to enable this checkbox.');
+  }
+  elseif(!BOOST_OVERWRITE_FILE) {
+    $description = t('The "Overwrite the cached file if it already exits" must be turned on in order to enable this.');
+  }
   $form['crawler']['boost_loopback_bypass'] = array(
     '#type'          => 'checkbox',
     '#title'         => t('Do not flush expired content on cron run, instead recrawl and overwrite it.'),
     '#default_value' => BOOST_LOOPBACK_BYPASS,
-    '#description'   => !BOOST_CRAWL_ON_CRON ? t('Enable the crawler first to enable this checkbox.') :!BOOST_OVERWRITE_FILE ? t('The "Overwrite the cached file if it already exits" must be turned on in order to enable this') : t('Bypass cron cache expiration and load to be expired content in the crawler. Allow this servers IP to bypass the boost cache. Check for fast but potentially stale; uncheck for slow but always fresh.'),
+    '#description'   => $description,
     '#disabled' => !BOOST_CRAWL_ON_CRON || !BOOST_OVERWRITE_FILE,
   );
+  if (BOOST_CRAWL_ON_CRON && BOOST_CACHE_HTML) {
+    $description = t('Crawl Site after cron runs, so the cache is primed.');
+  }
+  elseif(!BOOST_CRAWL_ON_CRON) {
+    $description = t('Enable the crawler first to enable this checkbox.');
+  }
+  elseif(!BOOST_CACHE_HTML) {
+    $description = t('Enable the caching of this content type to enable this checkbox');
+  }
   $form['crawler']['boost_push_html'] = array(
     '#type' => 'checkbox',
     '#title' => t('Preemptive Cache HTML'),
     '#default_value' => BOOST_PUSH_HTML,
-    '#description' => !BOOST_CRAWL_ON_CRON ? t('Enable the crawler first to enable this checkbox.') : !BOOST_CACHE_HTML ? t('Enable the caching of this content type to enable this checkbox') : t('Crawl Site after cron runs, so the cache is primed.'),
+    '#description' => $description,
     '#disabled' => !BOOST_CRAWL_ON_CRON || !BOOST_CACHE_HTML,
   );
+  if (BOOST_CRAWL_ON_CRON && BOOST_CACHE_XML) {
+    $description = t('Crawl Site after cron runs, so the cache is primed.');
+  }
+  elseif(!BOOST_CRAWL_ON_CRON) {
+    $description = t('Enable the crawler first to enable this checkbox.');
+  }
+  elseif(!BOOST_CACHE_XML) {
+    $description = t('Enable the caching of this content type to enable this checkbox');
+  }
   $form['crawler']['boost_push_xml'] = array(
     '#type' => 'checkbox',
     '#title' => t('Preemptive Cache XML'),
     '#default_value' => BOOST_PUSH_XML,
-    '#description' => !BOOST_CRAWL_ON_CRON ? t('Enable the crawler first to enable this checkbox.') : !BOOST_CACHE_XML ? t('Enable the caching of this content type to enable this checkbox') : t('Crawl Site after cron runs, so the cache is primed.'),
+    '#description' => $description,
     '#disabled' => !BOOST_CRAWL_ON_CRON || !BOOST_CACHE_XML,
   );
+  if (BOOST_CRAWL_ON_CRON && BOOST_CACHE_JSON) {
+    $description = t('Crawl Site after cron runs, so the cache is primed.');
+  }
+  elseif(!BOOST_CRAWL_ON_CRON) {
+    $description = t('Enable the crawler first to enable this checkbox.');
+  }
+  elseif(!BOOST_CACHE_JSON) {
+    $description = t('Enable the caching of this content type to enable this checkbox');
+  }
   $form['crawler']['boost_push_json'] = array(
     '#type' => 'checkbox',
     '#title' => t('Preemptive Cache AJAX/JSON'),
     '#default_value' => BOOST_PUSH_JSON,
-    '#description' => !BOOST_CRAWL_ON_CRON ? t('Enable the crawler first to enable this checkbox.') : !BOOST_CACHE_JSON ? t('Enable the caching of this content type to enable this checkbox') : t('Crawl Site after cron runs, so the cache is primed.'),
+    '#description' => $description,
     '#disabled' => !BOOST_CRAWL_ON_CRON || !BOOST_CACHE_JSON,
   );
   $form['crawler']['boost_crawl_url_alias'] = array(
Index: boost.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/boost/boost.module,v
retrieving revision 1.3.2.2.2.5.2.193
diff -u -p -r1.3.2.2.2.5.2.193 boost.module
--- boost.module	18 Oct 2009 08:19:15 -0000	1.3.2.2.2.5.2.193
+++ boost.module	18 Oct 2009 08:30:36 -0000
@@ -11,7 +11,7 @@
 
 define('BOOST_TIME',                 time());
 define('BOOST_MAX_TIMESTAMP',        variable_get('boost_max_timestamp', BOOST_TIME));
-define('BOOST_ENABLED',              variable_get('boost_enabled', CACHE_DISABLED));
+define('BOOST_ENABLED',              variable_get('boost_enabled', CACHE_NORMAL));
 define('BOOST_GZIP',                 variable_get('page_compression', TRUE));
 
 // This cookie is set for all authenticated users, so that they can be
@@ -29,8 +29,8 @@ define('BOOST_CACHE_XML_LIFETIME',   var
 define('BOOST_CACHE_JSON_LIFETIME',  variable_get('boost_cache_json_lifetime', 3600));
 define('BOOST_CACHE_QUERY',          variable_get('boost_cache_query', TRUE));
 define('BOOST_CACHE_HTML',           variable_get('boost_cache_html', TRUE));
-define('BOOST_CACHE_XML',            variable_get('boost_cache_xml', FALSE));
-define('BOOST_CACHE_JSON',           variable_get('boost_cache_json', FALSE));
+define('BOOST_CACHE_XML',            variable_get('boost_cache_xml', TRUE));
+define('BOOST_CACHE_JSON',           variable_get('boost_cache_json', TRUE));
 define('BOOST_CACHE_CSS',            variable_get('boost_cache_css', TRUE));
 define('BOOST_CACHE_JS',             variable_get('boost_cache_js', TRUE));
 define('BOOST_CACHEABILITY_OPTION',  variable_get('boost_cacheability_option', 0));
@@ -39,10 +39,10 @@ define('BOOST_CACHEABILITY_PAGES',   var
 // Dir & File Structure
 define('BOOST_ROOT_CACHE_DIR',       variable_get('boost_root_cache_dir', 'cache'));
 define('BOOST_MULTISITE_SINGLE_DB',  variable_get('boost_multisite_single_db', FALSE));
-define('BOOST_NORMAL_DIR',           variable_get('boost_normal_dir', ''));
-define('BOOST_GZIP_DIR',             variable_get('boost_gzip_dir', 'gz'));
-define('BOOST_PERM_NORMAL_DIR',      variable_get('boost_perm_normal_dir', ''));
-define('BOOST_PERM_GZ_DIR',          variable_get('boost_perm_gz_dir', 'gz'));
+define('BOOST_NORMAL_DIR',           variable_get('boost_normal_dir', 'normal'));
+define('BOOST_GZIP_DIR',             variable_get('boost_gzip_dir', 'normal'));
+define('BOOST_PERM_NORMAL_DIR',      variable_get('boost_perm_normal_dir', 'perm'));
+define('BOOST_PERM_GZ_DIR',          variable_get('boost_perm_gz_dir', 'perm'));
 define('BOOST_CHAR',                 variable_get('boost_char', '_'));
 define('BOOST_PERM_CHAR',            variable_get('boost_perm_char', '_'));
 define('BOOST_HOST',                 variable_get('boost_host', ''));
@@ -56,22 +56,22 @@ define('BOOST_ROOT_FILE',            var
 define('BOOST_MAX_PATH_DEPTH',       10);
 
 // Advanced Settings
-define('BOOST_CHECK_BEFORE_CRON_EXPIRE', variable_get('boost_check_before_cron_expire', FALSE));
+define('BOOST_CHECK_BEFORE_CRON_EXPIRE', variable_get('boost_check_before_cron_expire', TRUE));
 define('BOOST_PRE_PROCESS_FUNCTION', variable_get('boost_pre_process_function', ''));
 define('BOOST_FLUSH_ALL_MULTISITE',  variable_get('boost_flush_all_multisite', FALSE));
 define('BOOST_ONLY_ASCII_PATH',      variable_get('boost_only_ascii_path', TRUE));
 define('BOOST_ASYNCHRONOUS_OUTPUT',  variable_get('boost_asynchronous_output', TRUE));
-define('BOOST_FLUSH_DIR',            variable_get('boost_flush_dir', TRUE));
+define('BOOST_FLUSH_DIR',            variable_get('boost_flush_dir', FALSE));
 define('BOOST_FLUSH_CCK_REFERENCES', variable_get('boost_flush_cck_references', TRUE));
 define('BOOST_FLUSH_NODE_TERMS',     variable_get('boost_flush_node_terms', TRUE));
-define('BOOST_FLUSH_VIEWS',          variable_get('boost_flush_views', FALSE));
-define('BOOST_FLUSH_VIEWS_INSERT',   variable_get('boost_flush_views_insert', FALSE));
-define('BOOST_CLEAR_CACHE_OFFLINE',  variable_get('boost_clear_cache_offline', TRUE));
+define('BOOST_FLUSH_VIEWS',          variable_get('boost_flush_views', TRUE));
+define('BOOST_FLUSH_VIEWS_INSERT',   variable_get('boost_flush_views_insert', TRUE));
+define('BOOST_CLEAR_CACHE_OFFLINE',  variable_get('boost_clear_cache_offline', FALSE));
 define('BOOST_OVERWRITE_FILE',       variable_get('boost_overwrite_file', FALSE));
 define('BOOST_HALT_ON_ERRORS',       variable_get('boost_halt_on_errors', FALSE));
 define('BOOST_HALT_ON_MESSAGES',     variable_get('boost_halt_on_messages', TRUE));
 define('BOOST_DISABLE_CLEAN_URL',    variable_get('boost_disable_clean_url', FALSE));
-define('BOOST_AGGRESSIVE_GZIP',      variable_get('boost_aggressive_gzip', FALSE));
+define('BOOST_AGGRESSIVE_GZIP',      variable_get('boost_aggressive_gzip', TRUE));
 define('BOOST_PERMISSIONS_FILE',     variable_get('boost_permissions_file', ''));
 define('BOOST_PERMISSIONS_DIR',      variable_get('boost_permissions_dir', ''));
 define('BOOST_EXPIRE_NO_FLUSH',      variable_get('boost_expire_no_flush', FALSE));
@@ -79,10 +79,10 @@ define('BOOST_VERBOSE',              var
 
 // Crawler Settings
 define('BOOST_CRAWL_ON_CRON',        variable_get('boost_crawl_on_cron', FALSE));
-define('BOOST_LOOPBACK_BYPASS',      BOOST_OVERWRITE_FILE ? variable_get('boost_loopback_bypass', FALSE) : FALSE);
-define('BOOST_PUSH_HTML',            variable_get('boost_push_html', FALSE));
-define('BOOST_PUSH_XML',             variable_get('boost_push_xml', FALSE));
-define('BOOST_PUSH_JSON',            variable_get('boost_push_json', FALSE));
+define('BOOST_LOOPBACK_BYPASS',      BOOST_OVERWRITE_FILE && BOOST_CRAWL_ON_CRON ? variable_get('boost_loopback_bypass', FALSE) : TRUE);
+define('BOOST_PUSH_HTML',            variable_get('boost_push_html', TRUE));
+define('BOOST_PUSH_XML',             variable_get('boost_push_xml', TRUE));
+define('BOOST_PUSH_JSON',            variable_get('boost_push_json', TRUE));
 define('BOOST_CRAWLER_THROTTLE',     variable_get('boost_crawler_throttle', 0));
 define('BOOST_CRAWLER_THREADS',      variable_get('boost_crawler_threads', 2));
 define('BOOST_CRAWL_URL_ALIAS',      variable_get('boost_crawl_url_alias', FALSE));
Index: htaccess/boosted1.txt
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/boost/htaccess/Attic/boosted1.txt,v
retrieving revision 1.1.2.16
diff -u -p -r1.1.2.16 boosted1.txt
--- htaccess/boosted1.txt	14 Oct 2009 08:56:36 -0000	1.1.2.16
+++ htaccess/boosted1.txt	18 Oct 2009 08:30:36 -0000
@@ -31,22 +31,22 @@
   </FilesMatch>
 
   # Gzip Cookie Test
-  RewriteRule boost-gzip-cookie-test\.html  cache/gz/boost-gzip-cookie-test\.html\.gz [L,T=text/html]
+  RewriteRule boost-gzip-cookie-test\.html  cache/perm/boost-gzip-cookie-test\.html\.gz [L,T=text/html]
 
   # GZIP - Cached css & js files
   RewriteCond %{HTTP_COOKIE} !(boost-gzip)
   RewriteCond %{HTTP:Accept-encoding} !gzip
   RewriteRule .* - [S=2]
-  RewriteCond %{DOCUMENT_ROOT}/cache/gz/%{SERVER_NAME}%{REQUEST_URI}_\.css\.gz -s
-  RewriteRule .* cache/gz/%{SERVER_NAME}%{REQUEST_URI}_\.css\.gz [L,QSA,T=text/css]
-  RewriteCond %{DOCUMENT_ROOT}/cache/gz/%{SERVER_NAME}%{REQUEST_URI}_\.js\.gz -s
-  RewriteRule .* cache/gz/%{SERVER_NAME}%{REQUEST_URI}_\.js\.gz [L,QSA,T=text/javascript]
+  RewriteCond %{DOCUMENT_ROOT}/cache/perm/%{SERVER_NAME}%{REQUEST_URI}_\.css\.gz -s
+  RewriteRule .* cache/perm/%{SERVER_NAME}%{REQUEST_URI}_\.css\.gz [L,QSA,T=text/css]
+  RewriteCond %{DOCUMENT_ROOT}/cache/perm/%{SERVER_NAME}%{REQUEST_URI}_\.js\.gz -s
+  RewriteRule .* cache/perm/%{SERVER_NAME}%{REQUEST_URI}_\.js\.gz [L,QSA,T=text/javascript]
 
   # NORMAL - Cached css & js files
-  RewriteCond %{DOCUMENT_ROOT}/cache/%{SERVER_NAME}%{REQUEST_URI}_\.css -s
-  RewriteRule .* cache/%{SERVER_NAME}%{REQUEST_URI}_\.css [L,QSA,T=text/css]
-  RewriteCond %{DOCUMENT_ROOT}/cache/%{SERVER_NAME}%{REQUEST_URI}_\.js -s
-  RewriteRule .* cache/%{SERVER_NAME}%{REQUEST_URI}_\.js [L,QSA,T=text/javascript]
+  RewriteCond %{DOCUMENT_ROOT}/cache/perm/%{SERVER_NAME}%{REQUEST_URI}_\.css -s
+  RewriteRule .* cache/perm/%{SERVER_NAME}%{REQUEST_URI}_\.css [L,QSA,T=text/css]
+  RewriteCond %{DOCUMENT_ROOT}/cache/perm/%{SERVER_NAME}%{REQUEST_URI}_\.js -s
+  RewriteRule .* cache/perm/%{SERVER_NAME}%{REQUEST_URI}_\.js [L,QSA,T=text/javascript]
 
   # Caching for anonymous users
   # Skip boost IF not get request OR uri has wrong dir OR cookie is set OR https request
@@ -60,20 +60,20 @@
   RewriteCond %{HTTP_COOKIE} !(boost-gzip)
   RewriteCond %{HTTP:Accept-encoding} !gzip
   RewriteRule .* - [S=3]
-  RewriteCond %{DOCUMENT_ROOT}/cache/gz/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.html\.gz -s
-  RewriteRule .* cache/gz/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.html\.gz [L,T=text/html]
-  RewriteCond %{DOCUMENT_ROOT}/cache/gz/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.xml\.gz -s
-  RewriteRule .* cache/gz/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.xml\.gz [L,T=text/xml]
-  RewriteCond %{DOCUMENT_ROOT}/cache/gz/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.json\.gz -s
-  RewriteRule .* cache/gz/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.json\.gz [L,T=text/javascript]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.html\.gz -s
+  RewriteRule .* cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.html\.gz [L,T=text/html]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.xml\.gz -s
+  RewriteRule .* cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.xml\.gz [L,T=text/xml]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.json\.gz -s
+  RewriteRule .* cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.json\.gz [L,T=text/javascript]
 
   # NORMAL
-  RewriteCond %{DOCUMENT_ROOT}/cache/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.html -s
-  RewriteRule .* cache/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.html [L,T=text/html]
-  RewriteCond %{DOCUMENT_ROOT}/cache/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.xml -s
-  RewriteRule .* cache/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.xml [L,T=text/xml]
-  RewriteCond %{DOCUMENT_ROOT}/cache/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.json -s
-  RewriteRule .* cache/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.json [L,T=text/javascript]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.html -s
+  RewriteRule .* cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.html [L,T=text/html]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.xml -s
+  RewriteRule .* cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.xml [L,T=text/xml]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.json -s
+  RewriteRule .* cache/normal/%{SERVER_NAME}%{REQUEST_URI}_%{QUERY_STRING}\.json [L,T=text/javascript]
 
   ### BOOST END ###
 
Index: htaccess/boosted2.txt
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/boost/htaccess/Attic/boosted2.txt,v
retrieving revision 1.1.2.17
diff -u -p -r1.1.2.17 boosted2.txt
--- htaccess/boosted2.txt	14 Oct 2009 08:56:36 -0000	1.1.2.17
+++ htaccess/boosted2.txt	18 Oct 2009 08:30:36 -0000
@@ -31,22 +31,22 @@
   </FilesMatch>
 
   # Gzip Cookie Test
-  RewriteRule boost-gzip-cookie-test\.html  cache/gz/boost-gzip-cookie-test\.html\.gz [L,T=text/html]
+  RewriteRule boost-gzip-cookie-test\.html  cache/perm/boost-gzip-cookie-test\.html\.gz [L,T=text/html]
 
   # GZIP - Cached css & js files
   RewriteCond %{HTTP_COOKIE} !(boost-gzip)
   RewriteCond %{HTTP:Accept-encoding} !gzip
   RewriteRule .* - [S=2]
-  RewriteCond %{DOCUMENT_ROOT}/cache/gz/%{HTTP_HOST}%{REQUEST_URI}_\.css\.gz -s
-  RewriteRule .* cache/gz/%{HTTP_HOST}%{REQUEST_URI}_\.css\.gz [L,QSA,T=text/css]
-  RewriteCond %{DOCUMENT_ROOT}/cache/gz/%{HTTP_HOST}%{REQUEST_URI}_\.js\.gz -s
-  RewriteRule .* cache/gz/%{HTTP_HOST}%{REQUEST_URI}_\.js\.gz [L,QSA,T=text/javascript]
+  RewriteCond %{DOCUMENT_ROOT}/cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.css\.gz -s
+  RewriteRule .* cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.css\.gz [L,QSA,T=text/css]
+  RewriteCond %{DOCUMENT_ROOT}/cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.js\.gz -s
+  RewriteRule .* cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.js\.gz [L,QSA,T=text/javascript]
 
   # NORMAL - Cached css & js files
-  RewriteCond %{DOCUMENT_ROOT}/cache/%{HTTP_HOST}%{REQUEST_URI}_\.css -s
-  RewriteRule .* cache/%{HTTP_HOST}%{REQUEST_URI}_\.css [L,QSA,T=text/css]
-  RewriteCond %{DOCUMENT_ROOT}/cache/%{HTTP_HOST}%{REQUEST_URI}_\.js -s
-  RewriteRule .* cache/%{HTTP_HOST}%{REQUEST_URI}_\.js [L,QSA,T=text/javascript]
+  RewriteCond %{DOCUMENT_ROOT}/cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.css -s
+  RewriteRule .* cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.css [L,QSA,T=text/css]
+  RewriteCond %{DOCUMENT_ROOT}/cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.js -s
+  RewriteRule .* cache/perm/%{HTTP_HOST}%{REQUEST_URI}_\.js [L,QSA,T=text/javascript]
 
   # Caching for anonymous users
   # Skip boost IF not get request OR uri has wrong dir OR cookie is set OR https request
@@ -60,20 +60,20 @@
   RewriteCond %{HTTP_COOKIE} !(boost-gzip)
   RewriteCond %{HTTP:Accept-encoding} !gzip
   RewriteRule .* - [S=3]
-  RewriteCond %{DOCUMENT_ROOT}/cache/gz/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.html\.gz -s
-  RewriteRule .* cache/gz/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.html\.gz [L,T=text/html]
-  RewriteCond %{DOCUMENT_ROOT}/cache/gz/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.xml\.gz -s
-  RewriteRule .* cache/gz/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.xml\.gz [L,T=text/xml]
-  RewriteCond %{DOCUMENT_ROOT}/cache/gz/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.json\.gz -s
-  RewriteRule .* cache/gz/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.json\.gz [L,T=text/javascript]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.html\.gz -s
+  RewriteRule .* cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.html\.gz [L,T=text/html]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.xml\.gz -s
+  RewriteRule .* cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.xml\.gz [L,T=text/xml]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.json\.gz -s
+  RewriteRule .* cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.json\.gz [L,T=text/javascript]
 
   # NORMAL
-  RewriteCond %{DOCUMENT_ROOT}/cache/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.html -s
-  RewriteRule .* cache/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.html [L,T=text/html]
-  RewriteCond %{DOCUMENT_ROOT}/cache/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.xml -s
-  RewriteRule .* cache/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.xml [L,T=text/xml]
-  RewriteCond %{DOCUMENT_ROOT}/cache/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.json -s
-  RewriteRule .* cache/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.json [L,T=text/javascript]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.html -s
+  RewriteRule .* cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.html [L,T=text/html]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.xml -s
+  RewriteRule .* cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.xml [L,T=text/xml]
+  RewriteCond %{DOCUMENT_ROOT}/cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.json -s
+  RewriteRule .* cache/normal/%{HTTP_HOST}%{REQUEST_URI}_%{QUERY_STRING}\.json [L,T=text/javascript]
 
   ### BOOST END ###
 
