summaryrefslogtreecommitdiff
path: root/includes/common.inc
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2006-12-10 20:34:03 +0000
committerDries Buytaert <dries@buytaert.net>2006-12-10 20:34:03 +0000
commitbdf5dc9d1d18f15275362a0a717f33077a041d1e (patch)
tree9be87da028ba1733f83e1a664d775591d87a19f6 /includes/common.inc
parenta98fa4c2c883637939b8eb2510eb4706adac335f (diff)
downloadbrdo-bdf5dc9d1d18f15275362a0a717f33077a041d1e.tar.gz
brdo-bdf5dc9d1d18f15275362a0a717f33077a041d1e.tar.bz2
- Patch #102413 by yched: path node/add/[poll|forum|blog] defined twice.
Diffstat (limited to 'includes/common.inc')
-rw-r--r--includes/common.inc10
1 files changed, 5 insertions, 5 deletions
diff --git a/includes/common.inc b/includes/common.inc
index a82ad8e0c..f7ec8f735 100644
--- a/includes/common.inc
+++ b/includes/common.inc
@@ -1451,7 +1451,7 @@ function drupal_get_css($css = NULL) {
}
}
}
-
+
if ($is_writable && $preprocess_css) {
$filename = md5(serialize($types)) .'.css';
$preprocess_file = drupal_build_css_cache($types, $filename);
@@ -1478,7 +1478,7 @@ function drupal_build_css_cache($types, $filename) {
// Create the css/ within the files folder.
$csspath = file_create_path('css');
file_check_directory($csspath, FILE_CREATE_DIRECTORY);
-
+
if (!file_exists($csspath .'/'. $filename)) {
// Build aggregate CSS file.
foreach ($types as $type) {
@@ -1494,20 +1494,20 @@ function drupal_build_css_cache($types, $filename) {
}
}
}
-
+
// @import rules must proceed any other style, so we move those to the top.
$regexp = '/@import[^;]+;/i';
preg_match_all($regexp, $data, $matches);
$data = preg_replace($regexp, '', $data);
$data = implode('', $matches[0]) . $data;
-
+
// Perform some safe CSS optimizations.
$data = preg_replace('<
\s*([@{}:;\)])\s* | # Remove whitespace around separators.
/\*([^*\\\\]|\*(?!/))+\*/ | # Remove comments that are not CSS hacks.
[\n\r] # Remove line breaks.
>x', '\1', $data);
-
+
// Create the CSS file.
file_save_data($data, $csspath .'/'. $filename, FILE_EXISTS_REPLACE);
}