Autoptimize - Version 1.8.0

Version Description

  • New: Option to inline all CSS as suggested by Hamed
  • New: set of filters to provide a simple API to change Autoptimize behavior (e.g. replace "defer" with "async", disabling Autoptimization on certain pages, specificy non-aggregatable script to be moved after aggregated one (cfr. http://wordpress.org/support/topic/feature-request-some-extra-options?replies=14), size of image to be data-urized). More info in the included autoptimize_helper.php_example.
  • Improvement: exclude (css in) noscript-tags as proposed by belg4mit
  • Improvement: switch default delivery of optimized CSS/JS-files from PHP to static files
  • Updated upstream CSS minifier
  • Improvement (force gzip of static files) and Bugfix (force expiry for dynamic files, thanks to Willem Razenberg in .htaccess
  • Improvement: fail gracefully when things go wrong (e.g. CSS import resulting in empty aggregated CSS-files reported by Danka or when the theme is broken as seen by Prateek Gupta)
  • Updated translations and Polish added (thanks to Jakub Sierpinski).
  • Bugfix: stop import-statements in CSS comments to be taken into acccount hat tip to Josef from blog-it-solutions.de
  • Bugfix: fix for blur in CSS breakeage as reported by Chris of clickpanic.com
Download this release

Release Info

Developer futtta
Plugin Icon 128x128 Autoptimize
Version 1.8.0
Comparing to
See all releases

Code changes from version 1.7.3 to 1.8.0

autoptimize.php CHANGED
@@ -3,17 +3,24 @@
3
  Plugin Name: Autoptimize
4
  Plugin URI: http://blog.futtta.be/autoptimize
5
  Description: Optimizes your website, concatenating the CSS and JavaScript code, and compressing it.
6
- Version: 1.7.3
7
  Author: Frank Goossens (futtta)
8
  Author URI: http://blog.futtta.be/
 
 
9
  Released under the GNU General Public License (GPL)
10
  http://www.gnu.org/licenses/gpl.txt
11
  */
12
 
13
  if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
14
 
15
- // Load config and cache class
16
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeConfig.php');
 
 
 
 
 
17
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeCache.php');
18
 
19
  // Plugin dir constants (plugin url's defined later to accomodate domain mapped sites)
@@ -24,27 +31,58 @@ define('WP_ROOT_DIR',str_replace('/wp-content','',WP_CONTENT_DIR));
24
  // Initialize the cache at least once
25
  $conf = autoptimizeConfig::instance();
26
 
27
- /* Check if we're updating, in which case we need to flush the cache
28
  to avoid old versions of aggregated files lingering around */
29
 
30
- $autoptimize_version="1.7.3";
31
  $autoptimize_db_version=get_option('autoptimize_version','none');
32
 
33
  if ($autoptimize_db_version !== $autoptimize_version) {
34
  if ($autoptimize_db_version==="none") {
35
  add_action('admin_notices', 'autoptimize_install_config_notice');
36
- } else if (strpos($autoptimize_db_version,"1.6.")!==false) {
37
- // if user was on version 1.6.x, force advanced options to be shown by default
38
- update_option('autoptimize_show_adv','1');
39
-
40
- // and remove old options
41
- $delete_options=array("autoptimize_cdn_css","autoptimize_cdn_css_url","autoptimize_cdn_js","autoptimize_cdn_js_url","autoptimize_cdn_img","autoptimize_cdn_img_url","autoptimize_css_yui","autoptimize_js_yui");
42
- foreach ($delete_options as $del_opt) {
43
- delete_option( $del_opt );
44
- }
45
 
46
- // and notify user to check result
47
- add_action('admin_notices', 'autoptimize_update_config_notice');
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
48
  }
49
 
50
  autoptimizeCache::clearall();
@@ -52,9 +90,6 @@ if ($autoptimize_db_version !== $autoptimize_version) {
52
  $autoptimize_db_version=$autoptimize_version;
53
  }
54
 
55
- // Do we gzip when caching?
56
- define('AUTOPTIMIZE_CACHE_NOGZIP',(bool) $conf->get('autoptimize_cache_nogzip'));
57
-
58
  // Load translations
59
  $plugin_dir = basename(dirname(__FILE__));
60
  load_plugin_textdomain('autoptimize','wp-content/plugins/'.$plugin_dir.'/localization',$plugin_dir.'/localization');
@@ -62,7 +97,7 @@ load_plugin_textdomain('autoptimize','wp-content/plugins/'.$plugin_dir.'/localiz
62
  function autoptimize_uninstall(){
63
  autoptimizeCache::clearall();
64
 
65
- $delete_options=array("autoptimize_cache_clean", "autoptimize_cache_nogzip", "autoptimize_css", "autoptimize_css_datauris", "autoptimize_css_justhead", "autoptimize_css_defer", "autoptimize_css_exclude", "autoptimize_html", "autoptimize_html_keepcomments", "autoptimize_js", "autoptimize_js_exclude", "autoptimize_js_forcehead", "autoptimize_js_justhead", "autoptimize_js_trycatch", "autoptimize_version", "autoptimize_show_adv", "autoptimize_cdn_url");
66
 
67
  if ( !is_multisite() ) {
68
  foreach ($delete_options as $del_opt) { delete_option( $del_opt ); }
@@ -86,15 +121,19 @@ function autoptimize_install_config_notice() {
86
  }
87
 
88
  function autoptimize_update_config_notice() {
89
- echo '<div class="updated"><p>';
90
  _e('Autoptimize has just been updated. Please <strong>test your site now</strong> and adapt Autoptimize config if needed.', 'autoptimize' );
91
  echo '</p></div>';
92
  }
93
 
94
  // Set up the buffering
95
- function autoptimize_start_buffering()
96
- {
97
- if (!is_feed()) {
 
 
 
 
98
 
99
  // Config element
100
  $conf = autoptimizeConfig::instance();
@@ -103,8 +142,7 @@ function autoptimize_start_buffering()
103
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeBase.php');
104
 
105
  // Load extra classes and set some vars
106
- if($conf->get('autoptimize_html'))
107
- {
108
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeHTML.php');
109
  // BUG: new minify-html does not support keeping HTML comments, skipping for now
110
  // if (defined('AUTOPTIMIZE_LEGACY_MINIFIERS')) {
@@ -114,8 +152,7 @@ function autoptimize_start_buffering()
114
  // }
115
  }
116
 
117
- if($conf->get('autoptimize_js'))
118
- {
119
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeScripts.php');
120
  if (!class_exists('JSMin')) {
121
  if (defined('AUTOPTIMIZE_LEGACY_MINIFIERS')) {
@@ -128,8 +165,7 @@ function autoptimize_start_buffering()
128
  define('COMPRESS_SCRIPTS',false);
129
  }
130
 
131
- if($conf->get('autoptimize_css'))
132
- {
133
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeStyles.php');
134
  if (defined('AUTOPTIMIZE_LEGACY_MINIFIERS')) {
135
  if (!class_exists('Minify_CSS_Compressor')) {
@@ -137,7 +173,7 @@ function autoptimize_start_buffering()
137
  }
138
  } else {
139
  if (!class_exists('CSSmin')) {
140
- @include(WP_PLUGIN_DIR.'/autoptimize/classes/external/php/yui-php-cssmin-2.4.8-1.php');
141
  }
142
  }
143
  define('COMPRESS_CSS',false);
@@ -149,13 +185,12 @@ function autoptimize_start_buffering()
149
  }
150
 
151
  //Action on end -
152
- function autoptimize_end_buffering($content)
153
- {
154
  if ( stripos($content,"<html") === false || stripos($content,"<xsl:stylesheet") !== false ) { return $content;}
155
 
156
  // load URL constants as late as possible to allow domain mapper to kick in
157
- if (function_exists(domain_mapping_siteurl)) {
158
- define('AUTOPTIMIZE_WP_SITE_URL',domain_mapping_siteurl());
159
  define('AUTOPTIMIZE_WP_CONTENT_URL',str_replace(get_original_url(AUTOPTIMIZE_WP_SITE_URL),AUTOPTIMIZE_WP_SITE_URL,content_url()));
160
  } else {
161
  define('AUTOPTIMIZE_WP_SITE_URL',site_url());
@@ -163,6 +198,7 @@ function autoptimize_end_buffering($content)
163
  }
164
  define('AUTOPTIMIZE_CACHE_URL',AUTOPTIMIZE_WP_CONTENT_URL.'/cache/autoptimize/');
165
  define('AUTOPTIMIZE_WP_ROOT_URL',str_replace('/wp-content','',AUTOPTIMIZE_WP_CONTENT_URL));
 
166
  // Config element
167
  $conf = autoptimizeConfig::instance();
168
 
@@ -188,6 +224,7 @@ function autoptimize_end_buffering($content)
188
  'justhead' => $conf->get('autoptimize_css_justhead'),
189
  'datauris' => $conf->get('autoptimize_css_datauris'),
190
  'defer' => $conf->get('autoptimize_css_defer'),
 
191
  'css_exclude' => $conf->get('autoptimize_css_exclude'),
192
  'cdn_url' => $conf->get('autoptimize_cdn_url')
193
  ),
@@ -198,8 +235,7 @@ function autoptimize_end_buffering($content)
198
 
199
 
200
  // Run the classes
201
- foreach($classes as $name)
202
- {
203
  $instance = new $name($content);
204
  if($instance->read($classoptions[$name]))
205
  {
@@ -212,11 +248,9 @@ function autoptimize_end_buffering($content)
212
  return $content;
213
  }
214
 
215
- if(autoptimizeCache::cacheavail())
216
- {
217
  $conf = autoptimizeConfig::instance();
218
- if( $conf->get('autoptimize_html') || $conf->get('autoptimize_js') || $conf->get('autoptimize_css') || $conf->get('autoptimize_cdn_js') || $conf->get('autoptimize_cdn_css'))
219
- {
220
  // Hook to wordpress
221
  add_action('template_redirect','autoptimize_start_buffering',2);
222
  }
3
  Plugin Name: Autoptimize
4
  Plugin URI: http://blog.futtta.be/autoptimize
5
  Description: Optimizes your website, concatenating the CSS and JavaScript code, and compressing it.
6
+ Version: 1.8.0
7
  Author: Frank Goossens (futtta)
8
  Author URI: http://blog.futtta.be/
9
+ Domain Path: localization/
10
+ Text Domain: autoptimize
11
  Released under the GNU General Public License (GPL)
12
  http://www.gnu.org/licenses/gpl.txt
13
  */
14
 
15
  if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
16
 
17
+ // Load config class
18
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeConfig.php');
19
+
20
+ // Do we gzip when caching (needed early to load autoptimizeCache.php)
21
+ define('AUTOPTIMIZE_CACHE_NOGZIP',(bool) get_option('autoptimize_cache_nogzip'));
22
+
23
+ // Load cache class
24
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeCache.php');
25
 
26
  // Plugin dir constants (plugin url's defined later to accomodate domain mapped sites)
31
  // Initialize the cache at least once
32
  $conf = autoptimizeConfig::instance();
33
 
34
+ /* Check if we're updating, in which case we might need to do stuff and flush the cache
35
  to avoid old versions of aggregated files lingering around */
36
 
37
+ $autoptimize_version="1.8.0";
38
  $autoptimize_db_version=get_option('autoptimize_version','none');
39
 
40
  if ($autoptimize_db_version !== $autoptimize_version) {
41
  if ($autoptimize_db_version==="none") {
42
  add_action('admin_notices', 'autoptimize_install_config_notice');
43
+ } else {
44
+ $autoptimize_major_version=substr($autoptimize_db_version,0,3);
45
+ switch($autoptimize_major_version) {
46
+ case "1.6":
47
+ // from back in the days when I did not yet consider multisite
48
+ // if user was on version 1.6.x, force advanced options to be shown by default
49
+ update_option('autoptimize_show_adv','1');
 
 
50
 
51
+ // and remove old options
52
+ $to_delete_options=array("autoptimize_cdn_css","autoptimize_cdn_css_url","autoptimize_cdn_js","autoptimize_cdn_js_url","autoptimize_cdn_img","autoptimize_cdn_img_url","autoptimize_css_yui","autoptimize_js_yui");
53
+ foreach ($to_delete_options as $del_opt) {
54
+ delete_option( $del_opt );
55
+ }
56
+
57
+ // and notify user to check result
58
+ add_action('admin_notices', 'autoptimize_update_config_notice');
59
+ case "1.7":
60
+ // force 3.8 dashicons in CSS exclude options when upgrading from 1.7 to 1.8
61
+ if ( !is_multisite() ) {
62
+ $css_exclude = get_option('autoptimize_css_exclude');
63
+ if (empty($css_exclude)) {
64
+ $css_exclude = "admin-bar.min.css, dashicons.min.css";
65
+ } else if (strpos($css_exclude,"dashicons.min.css")===false) {
66
+ $css_exclude .= ", dashicons.min.css";
67
+ }
68
+ update_option('autoptimize_css_exclude',$css_exclude);
69
+ } else {
70
+ global $wpdb;
71
+ $blog_ids = $wpdb->get_col( "SELECT blog_id FROM $wpdb->blogs" );
72
+ $original_blog_id = get_current_blog_id();
73
+ foreach ( $blog_ids as $blog_id ) {
74
+ switch_to_blog( $blog_id );
75
+ $css_exclude = get_option('autoptimize_css_exclude');
76
+ if (empty($css_exclude)) {
77
+ $css_exclude = "admin-bar.min.css, dashicons.min.css";
78
+ } else if (strpos($css_exclude,"dashicons.min.css")===false) {
79
+ $css_exclude .= ", dashicons.min.css";
80
+ }
81
+ update_option('autoptimize_css_exclude',$css_exclude);
82
+ }
83
+ switch_to_blog( $original_blog_id );
84
+ }
85
+ }
86
  }
87
 
88
  autoptimizeCache::clearall();
90
  $autoptimize_db_version=$autoptimize_version;
91
  }
92
 
 
 
 
93
  // Load translations
94
  $plugin_dir = basename(dirname(__FILE__));
95
  load_plugin_textdomain('autoptimize','wp-content/plugins/'.$plugin_dir.'/localization',$plugin_dir.'/localization');
97
  function autoptimize_uninstall(){
98
  autoptimizeCache::clearall();
99
 
100
+ $delete_options=array("autoptimize_cache_clean", "autoptimize_cache_nogzip", "autoptimize_css", "autoptimize_css_datauris", "autoptimize_css_justhead", "autoptimize_css_defer", "autoptimize_css_inline", "autoptimize_css_exclude", "autoptimize_html", "autoptimize_html_keepcomments", "autoptimize_js", "autoptimize_js_exclude", "autoptimize_js_forcehead", "autoptimize_js_justhead", "autoptimize_js_trycatch", "autoptimize_version", "autoptimize_show_adv", "autoptimize_cdn_url");
101
 
102
  if ( !is_multisite() ) {
103
  foreach ($delete_options as $del_opt) { delete_option( $del_opt ); }
121
  }
122
 
123
  function autoptimize_update_config_notice() {
124
+ echo '<div class="updated"><p>';
125
  _e('Autoptimize has just been updated. Please <strong>test your site now</strong> and adapt Autoptimize config if needed.', 'autoptimize' );
126
  echo '</p></div>';
127
  }
128
 
129
  // Set up the buffering
130
+ function autoptimize_start_buffering() {
131
+ $ao_noptimize = false;
132
+
133
+ // filter you can use to block autoptimization on your own terms
134
+ $ao_noptimize = (bool) apply_filters( 'autoptimize_filter_noptimize', $ao_noptimize );
135
+
136
+ if (!is_feed() && !$ao_noptimize ) {
137
 
138
  // Config element
139
  $conf = autoptimizeConfig::instance();
142
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeBase.php');
143
 
144
  // Load extra classes and set some vars
145
+ if($conf->get('autoptimize_html')) {
 
146
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeHTML.php');
147
  // BUG: new minify-html does not support keeping HTML comments, skipping for now
148
  // if (defined('AUTOPTIMIZE_LEGACY_MINIFIERS')) {
152
  // }
153
  }
154
 
155
+ if($conf->get('autoptimize_js')) {
 
156
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeScripts.php');
157
  if (!class_exists('JSMin')) {
158
  if (defined('AUTOPTIMIZE_LEGACY_MINIFIERS')) {
165
  define('COMPRESS_SCRIPTS',false);
166
  }
167
 
168
+ if($conf->get('autoptimize_css')) {
 
169
  include(WP_PLUGIN_DIR.'/autoptimize/classes/autoptimizeStyles.php');
170
  if (defined('AUTOPTIMIZE_LEGACY_MINIFIERS')) {
171
  if (!class_exists('Minify_CSS_Compressor')) {
173
  }
174
  } else {
175
  if (!class_exists('CSSmin')) {
176
+ @include(WP_PLUGIN_DIR.'/autoptimize/classes/external/php/yui-php-cssmin-2.4.8-2_fgo.php');
177
  }
178
  }
179
  define('COMPRESS_CSS',false);
185
  }
186
 
187
  //Action on end -
188
+ function autoptimize_end_buffering($content) {
 
189
  if ( stripos($content,"<html") === false || stripos($content,"<xsl:stylesheet") !== false ) { return $content;}
190
 
191
  // load URL constants as late as possible to allow domain mapper to kick in
192
+ if (function_exists("domain_mapping_siteurl")) {
193
+ define('AUTOPTIMIZE_WP_SITE_URL',domain_mapping_siteurl(get_current_blog_id()));
194
  define('AUTOPTIMIZE_WP_CONTENT_URL',str_replace(get_original_url(AUTOPTIMIZE_WP_SITE_URL),AUTOPTIMIZE_WP_SITE_URL,content_url()));
195
  } else {
196
  define('AUTOPTIMIZE_WP_SITE_URL',site_url());
198
  }
199
  define('AUTOPTIMIZE_CACHE_URL',AUTOPTIMIZE_WP_CONTENT_URL.'/cache/autoptimize/');
200
  define('AUTOPTIMIZE_WP_ROOT_URL',str_replace('/wp-content','',AUTOPTIMIZE_WP_CONTENT_URL));
201
+
202
  // Config element
203
  $conf = autoptimizeConfig::instance();
204
 
224
  'justhead' => $conf->get('autoptimize_css_justhead'),
225
  'datauris' => $conf->get('autoptimize_css_datauris'),
226
  'defer' => $conf->get('autoptimize_css_defer'),
227
+ 'inline' => $conf->get('autoptimize_css_inline'),
228
  'css_exclude' => $conf->get('autoptimize_css_exclude'),
229
  'cdn_url' => $conf->get('autoptimize_cdn_url')
230
  ),
235
 
236
 
237
  // Run the classes
238
+ foreach($classes as $name) {
 
239
  $instance = new $name($content);
240
  if($instance->read($classoptions[$name]))
241
  {
248
  return $content;
249
  }
250
 
251
+ if(autoptimizeCache::cacheavail()) {
 
252
  $conf = autoptimizeConfig::instance();
253
+ if( $conf->get('autoptimize_html') || $conf->get('autoptimize_js') || $conf->get('autoptimize_css') || $conf->get('autoptimize_cdn_js') || $conf->get('autoptimize_cdn_css')) {
 
254
  // Hook to wordpress
255
  add_action('template_redirect','autoptimize_start_buffering',2);
256
  }
autoptimize_helper.php_example ADDED
@@ -0,0 +1,35 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ // add_filter('autoptimize_filter_css_datauri_maxsize','my_ao_override_dataursize',10,1);
3
+ function my_ao_override_dataursize($urisizeIn) {
4
+ return 10000;
5
+ }
6
+
7
+ // add_filter('autoptimize_filter_js_defer','my_ao_override_defer',10,1);
8
+ function my_ao_override_defer($defer) {
9
+ return $defer."async ";
10
+ }
11
+
12
+ // add_filter('autoptimize_filter_noptimize','my_ao_noptimize',10,0);
13
+ function my_ao_noptimize() {
14
+ if (strpos($_SERVER['REQUEST_URI'],'no-autoptimize-now')!==false) {
15
+ return true;
16
+ } else {
17
+ return false;
18
+ }
19
+ }
20
+
21
+ // add_filter('autoptimize_filter_js_exclude','my_ao_override_jsexclude',10,1);
22
+ function my_ao_override_jsexclude($exclude) {
23
+ return $exclude.", customize-support";
24
+ }
25
+
26
+ // add_filter('autoptimize_filter_css_exclude','my_ao_override_cssexclude',10,1);
27
+ function my_ao_override_cssexclude($exclude) {
28
+ return $exclude.", recentcomments";
29
+ }
30
+
31
+ // add_filter('autoptimize_filter_js_movelast','my_ao_override_movelast',10,1);
32
+ function my_ao_override_movelast($movelast) {
33
+ $movelast[]="console.log";
34
+ return $movelast;
35
+ }
classes/autoptimizeBase.php CHANGED
@@ -24,27 +24,26 @@ abstract class autoptimizeBase
24
  abstract public function getcontent();
25
 
26
  //Converts an URL to a full path
27
- protected function getpath($url)
28
- {
29
-
30
  if ((strpos($url,'//')===false) && (strpos($url,parse_url(AUTOPTIMIZE_WP_SITE_URL,PHP_URL_HOST))===false)) {
31
  $url = AUTOPTIMIZE_WP_SITE_URL.$url;
32
  }
33
- $path = str_replace(AUTOPTIMIZE_WP_ROOT_URL,'',$url);
34
- if(preg_match('#^((https?|ftp):)?//#i',$path))
35
- {
36
- /** External script/css (adsense, etc) */
37
- return false;
38
- }
39
- $path = str_replace('//','/',WP_ROOT_DIR.$path);
40
- return $path;
41
  }
 
42
  // logger
43
  protected function ao_logger($logmsg) {
44
  $logfile=WP_CONTENT_DIR.'/ao_log.txt';
45
  $logmsg.="\n";
46
  file_put_contents($logfile,$logmsg,FILE_APPEND);
47
  }
 
48
  // hide everything between noptimize-comment tags
49
  protected function hide_noptimize($noptimize_in) {
50
  if ( preg_match( '/<!--\s?noptimize\s?-->/', $noptimize_in ) ) {
@@ -64,7 +63,7 @@ abstract class autoptimizeBase
64
 
65
  // unhide noptimize-tags
66
  protected function restore_noptimize($noptimize_in) {
67
- if ( preg_match( '/%%NOPTIMIZE%%/', $noptimize_in ) ) {
68
  $noptimize_out = preg_replace_callback(
69
  '#%%NOPTIMIZE%%(.*?)%%NOPTIMIZE%%#is',
70
  create_function(
@@ -78,15 +77,47 @@ abstract class autoptimizeBase
78
  }
79
  return $noptimize_out;
80
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
81
 
82
- protected function url_replace_cdn($url) {
83
-
84
  if (!empty($this->cdn_url)) {
85
- // this check is too expensive, is done on admin-screen
86
- // if (preg_match("/^(https?)?:\/\/([\da-z\.-]+)\.([\da-z\.]{2,6})([\/\w \.-]*)*\/?$/",$this->cdn_url)) {
87
- $url=str_replace(AUTOPTIMIZE_WP_SITE_URL,rtrim($this->cdn_url,'/'),$url);
88
- // }
89
  }
90
  return $url;
91
  }
 
 
 
 
92
  }
24
  abstract public function getcontent();
25
 
26
  //Converts an URL to a full path
27
+ protected function getpath($url) {
 
 
28
  if ((strpos($url,'//')===false) && (strpos($url,parse_url(AUTOPTIMIZE_WP_SITE_URL,PHP_URL_HOST))===false)) {
29
  $url = AUTOPTIMIZE_WP_SITE_URL.$url;
30
  }
31
+ $path = str_replace(AUTOPTIMIZE_WP_ROOT_URL,'',$url);
32
+ if(preg_match('#^((https?|ftp):)?//#i',$path)) {
33
+ /** External script/css (adsense, etc) */
34
+ return false;
35
+ }
36
+ $path = str_replace('//','/',WP_ROOT_DIR.$path);
37
+ return $path;
 
38
  }
39
+
40
  // logger
41
  protected function ao_logger($logmsg) {
42
  $logfile=WP_CONTENT_DIR.'/ao_log.txt';
43
  $logmsg.="\n";
44
  file_put_contents($logfile,$logmsg,FILE_APPEND);
45
  }
46
+
47
  // hide everything between noptimize-comment tags
48
  protected function hide_noptimize($noptimize_in) {
49
  if ( preg_match( '/<!--\s?noptimize\s?-->/', $noptimize_in ) ) {
63
 
64
  // unhide noptimize-tags
65
  protected function restore_noptimize($noptimize_in) {
66
+ if ( strpos( $noptimize_in, '%%NOPTIMIZE%%' ) !== false ) {
67
  $noptimize_out = preg_replace_callback(
68
  '#%%NOPTIMIZE%%(.*?)%%NOPTIMIZE%%#is',
69
  create_function(
77
  }
78
  return $noptimize_out;
79
  }
80
+
81
+ protected function hide_iehacks($iehacks_in) {
82
+ if ( strpos( $iehacks_in, '<!--[if' ) !== false ) {
83
+ $iehacks_out = preg_replace_callback(
84
+ '#<!--[if.*?[endif]-->#is',
85
+ create_function(
86
+ '$matches',
87
+ 'return "%%IEHACK%%".base64_encode($matches[0])."%%IEHACK%%";'
88
+ ),
89
+ $iehacks_in
90
+ );
91
+ } else {
92
+ $iehacks_out = $iehacks_in;
93
+ }
94
+ return $iehacks_out;
95
+ }
96
+
97
+ protected function restore_iehacks($iehacks_in) {
98
+ if ( strpos( $iehacks_in, '%%IEHACK%%' ) !== false ) {
99
+ $iehacks_out = preg_replace_callback(
100
+ '#%%IEHACK%%(.*?)%%IEHACK%%#is',
101
+ create_function(
102
+ '$matches',
103
+ 'return stripslashes(base64_decode($matches[1]));'
104
+ ),
105
+ $iehacks_in
106
+ );
107
+ } else {
108
+ $iehacks_out=$iehacks_in;
109
+ }
110
+ return $iehacks_out;
111
+ }
112
 
113
+ protected function url_replace_cdn($url) {
 
114
  if (!empty($this->cdn_url)) {
115
+ $url=str_replace(AUTOPTIMIZE_WP_SITE_URL,rtrim($this->cdn_url,'/'),$url);
 
 
 
116
  }
117
  return $url;
118
  }
119
+
120
+ protected function warn_html() {
121
+ $this->content .= "<!--noptimize--><!-- Autoptimize found a problem with the HTML in your Theme, check if the title or body-tags are missing --><!--/noptimize-->";
122
+ }
123
  }
classes/autoptimizeCache.php CHANGED
@@ -175,7 +175,8 @@ class autoptimizeCache
175
  /** write .htaccess here to overrule wp_super_cache */
176
  $htAccess=AUTOPTIMIZE_CACHE_DIR.'/.htaccess';
177
  if(!is_file($htAccess)) {
178
- if (is_multisite()) {@file_put_contents($htAccess,'<IfModule mod_headers.c>
 
179
  Header set Vary "Accept-Encoding"
180
  Header set Cache-Control "max-age=10672000, must-revalidate"
181
  </IfModule>
@@ -185,12 +186,13 @@ class autoptimizeCache
185
  ExpiresByType text/javascript A30672000
186
  ExpiresByType application/javascript A30672000
187
  </IfModule>
 
 
 
 
 
188
  <Files *.php>
189
  Allow from all
190
- </Files>');
191
- } else if (AUTOPTIMIZE_CACHE_NOGZIP == false) {
192
- @file_put_contents($htAccess,'<Files *.php>
193
- Allow from all
194
  </Files>');
195
  } else {
196
  @file_put_contents($htAccess,'<IfModule mod_headers.c>
@@ -203,6 +205,11 @@ class autoptimizeCache
203
  ExpiresByType text/javascript A30672000
204
  ExpiresByType application/javascript A30672000
205
  </IfModule>
 
 
 
 
 
206
  <Files *.php>
207
  Deny from all
208
  </Files>');
175
  /** write .htaccess here to overrule wp_super_cache */
176
  $htAccess=AUTOPTIMIZE_CACHE_DIR.'/.htaccess';
177
  if(!is_file($htAccess)) {
178
+ if (is_multisite() || AUTOPTIMIZE_CACHE_NOGZIP == false) {
179
+ @file_put_contents($htAccess,'<IfModule mod_headers.c>
180
  Header set Vary "Accept-Encoding"
181
  Header set Cache-Control "max-age=10672000, must-revalidate"
182
  </IfModule>
186
  ExpiresByType text/javascript A30672000
187
  ExpiresByType application/javascript A30672000
188
  </IfModule>
189
+ <IfModule mod_deflate.c>
190
+ <FilesMatch "\.(js|css)$">
191
+ SetOutputFilter DEFLATE
192
+ </FilesMatch>
193
+ </IfModule>
194
  <Files *.php>
195
  Allow from all
 
 
 
 
196
  </Files>');
197
  } else {
198
  @file_put_contents($htAccess,'<IfModule mod_headers.c>
205
  ExpiresByType text/javascript A30672000
206
  ExpiresByType application/javascript A30672000
207
  </IfModule>
208
+ <IfModule mod_deflate.c>
209
+ <FilesMatch "\.(js|css)$">
210
+ SetOutputFilter DEFLATE
211
+ </FilesMatch>
212
+ </IfModule>
213
  <Files *.php>
214
  Deny from all
215
  </Files>');
classes/autoptimizeConfig.php CHANGED
@@ -49,7 +49,7 @@ class autoptimizeConfig
49
  public function show()
50
  {
51
  ?>
52
- <style>input[type=url]:invalid {color: red; border-color:red;}</style>
53
 
54
  <div class="wrap">
55
 
@@ -104,9 +104,9 @@ if (get_option('autoptimize_show_adv','0')=='1') {
104
  <?php _e('Mostly usefull in combination with previous option when using jQuery-based templates, but might help keeping cache size under control.','autoptimize'); ?></label></td>
105
  </tr>
106
  <tr valign="top" class="hidden ao_adv">
107
- <th scope="row"><?php _e('Exclude scripts from autoptimize:','autoptimize'); ?></th>
108
  <td><label for="autoptimize_js_exclude"><input type="text" style="width:100%;" name="autoptimize_js_exclude" value="<?php echo get_option('autoptimize_js_exclude',"s_sid,smowtion_size,sc_project,WAU_,wau_add,comment-form-quicktags,edToolbar,ch_client"); ?>"/><br />
109
- <?php _e('A comma-seperated list of scripts you want to exclude from being Autoptimized, for example \'whatever.js, another.js\' (without the quotes) to exclude those scripts from being aggregated and minimized by Autoptimize.','autoptimize'); ?></label></td>
110
  </tr>
111
  <tr valign="top" class="hidden ao_adv">
112
  <th scope="row"><?php _e('Add try-catch wrapping?','autoptimize'); ?></th>
@@ -127,19 +127,24 @@ if (get_option('autoptimize_show_adv','0')=='1') {
127
  <?php _e('Enable this to include small background-images in the CSS itself instead of as seperate downloads.','autoptimize'); ?></label></td>
128
  </tr>
129
  <tr valign="top" class="hidden ao_adv">
130
- <th scope="row"><?php _e('Defer CSS loading?','autoptimize'); ?></th>
131
- <td><label for="autoptimize_css_defer"><input type="checkbox" name="autoptimize_css_defer" <?php echo get_option('autoptimize_css_defer')?'checked="checked" ':''; ?>/>
132
- <?php _e('Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for mobile performance reasons having it deferred can be better. ','autoptimize'); _e('<strong>Warning</strong>: this can slow down your site, <a href="http://wordpress.org/plugins/autoptimize/faq/" target="_blank">check the FAQ</a> before activating this option!','autoptimize'); ?></label></td>
133
- </tr>
134
- <tr valign="top" class="hidden ao_adv">
135
  <th scope="row"><?php _e('Look for styles only in &lt;head&gt;?','autoptimize'); ?></th>
136
  <td><label for="autoptimize_css_justhead"><input type="checkbox" name="autoptimize_css_justhead" <?php echo get_option('autoptimize_css_justhead')?'checked="checked" ':''; ?>/>
137
  <?php _e('Don\'t autoptimize CSS outside the head-section. If the cache gets big, you might want to enable this.','autoptimize'); ?></label></td>
138
  </tr>
139
  <tr valign="top" class="hidden ao_adv">
140
- <th scope="row"><?php _e('Exclude CSS from autoptimize:','autoptimize'); ?></th>
141
- <td><label for="autoptimize_css_exclude"><input type="text" style="width:100%;" name="autoptimize_css_exclude" value="<?php echo get_option('autoptimize_css_exclude','admin-bar.min.css'); ?>"/><br />
142
- <?php _e('A comma-seperated list of CSS you want to exclude from being Autoptimized.','autoptimize'); ?></label></td>
 
 
 
 
 
 
 
 
 
 
143
  </tr>
144
  </table>
145
 
@@ -148,7 +153,7 @@ if (get_option('autoptimize_show_adv','0')=='1') {
148
  <tr valign="top">
149
  <th scope="row"><?php _e('CDN Base URL','autoptimize'); ?></th>
150
  <td><label for="autoptimize_url"><input id="cdn_url" type="url" name="autoptimize_cdn_url" pattern="^(https?:)?\/\/([\da-z\.-]+)\.([\da-z\.]{2,6})([\/\w \.-]*)*\/?$" style="width:100%" value="<?php $it = get_option('autoptimize_cdn_url','');echo htmlentities($it); ?>" /><br />
151
- <?php _e('Enter your CDN blog root directory URL if you want to enable CDN.','autoptimize'); ?></label></td>
152
  </tr>
153
  </table>
154
 
@@ -168,15 +173,15 @@ if (get_option('autoptimize_show_adv','0')=='1') {
168
  </tr>
169
  <tr valign="top" class="hidden ao_adv">
170
  <th scope="row"><?php _e('Save aggregated script/css as static files?','autoptimize'); ?></th>
171
- <td><label for="autoptimize_cache_nogzip"><input type="checkbox" name="autoptimize_cache_nogzip" <?php echo get_option('autoptimize_cache_nogzip')?'checked="checked" ':''; ?>/>
172
- <?php _e('Enable this if your webserver can handle the compression and expiry.','autoptimize'); ?></label></td>
173
  </tr>
174
  </table>
175
  <input type="hidden" id="autoptimize_show_adv" name="autoptimize_show_adv" value="<?php echo get_option('autoptimize_show_adv','0'); ?>">
176
 
177
  <p class="submit">
178
- <input type="submit" class="button-secondary" value="<?php _e('Save Changes') ?>" />
179
- <input type="submit" class="button-primary" name="autoptimize_cache_clean" value="<?php _e('Save Changes and Empty Cache') ?>" />
180
  </p>
181
 
182
  </form>
@@ -218,6 +223,18 @@ if (get_option('autoptimize_show_adv','0')=='1') {
218
  jQuery( "input#autoptimize_show_adv" ).val("0");
219
  });
220
 
 
 
 
 
 
 
 
 
 
 
 
 
221
  jQuery("#feed_dropdown").change(function() { show_feed(jQuery("#feed_dropdown").val()) });
222
  feedid=jQuery.cookie(cookiename);
223
  if(typeof(feedid) !== "string") feedid=1;
@@ -271,6 +288,7 @@ if (get_option('autoptimize_show_adv','0')=='1') {
271
  register_setting('autoptimize','autoptimize_css_justhead');
272
  register_setting('autoptimize','autoptimize_css_datauris');
273
  register_setting('autoptimize','autoptimize_css_defer');
 
274
  register_setting('autoptimize','autoptimize_cdn_url');
275
  register_setting('autoptimize','autoptimize_cache_clean');
276
  register_setting('autoptimize','autoptimize_cache_nogzip');
@@ -316,12 +334,13 @@ if (get_option('autoptimize_show_adv','0')=='1') {
316
  'autoptimize_js_justhead' => 0,
317
  'autoptimize_js_forcehead' => 0,
318
  'autoptimize_css' => 0,
319
- 'autoptimize_css_exclude' => "admin-bar.min.css",
320
  'autoptimize_css_justhead' => 0,
321
  'autoptimize_css_defer' => 0,
 
322
  'autoptimize_css_datauris' => 0,
323
  'autoptimize_cdn_url' => "",
324
- 'autoptimize_cache_nogzip' => 0,
325
  'autoptimize_show_adv' => 0
326
  );
327
 
49
  public function show()
50
  {
51
  ?>
52
+ <style>input[type=url]:invalid {color: red; border-color:red;} .form-table th{font-weight:100;}</style>
53
 
54
  <div class="wrap">
55
 
104
  <?php _e('Mostly usefull in combination with previous option when using jQuery-based templates, but might help keeping cache size under control.','autoptimize'); ?></label></td>
105
  </tr>
106
  <tr valign="top" class="hidden ao_adv">
107
+ <th scope="row"><?php _e('Exclude scripts from Autoptimize:','autoptimize'); ?></th>
108
  <td><label for="autoptimize_js_exclude"><input type="text" style="width:100%;" name="autoptimize_js_exclude" value="<?php echo get_option('autoptimize_js_exclude',"s_sid,smowtion_size,sc_project,WAU_,wau_add,comment-form-quicktags,edToolbar,ch_client"); ?>"/><br />
109
+ <?php _e('A comma-seperated list of scripts you want to exclude from being optimized, for example \'whatever.js, another.js\' (without the quotes) to exclude those scripts from being aggregated and minimized by Autoptimize.','autoptimize'); ?></label></td>
110
  </tr>
111
  <tr valign="top" class="hidden ao_adv">
112
  <th scope="row"><?php _e('Add try-catch wrapping?','autoptimize'); ?></th>
127
  <?php _e('Enable this to include small background-images in the CSS itself instead of as seperate downloads.','autoptimize'); ?></label></td>
128
  </tr>
129
  <tr valign="top" class="hidden ao_adv">
 
 
 
 
 
130
  <th scope="row"><?php _e('Look for styles only in &lt;head&gt;?','autoptimize'); ?></th>
131
  <td><label for="autoptimize_css_justhead"><input type="checkbox" name="autoptimize_css_justhead" <?php echo get_option('autoptimize_css_justhead')?'checked="checked" ':''; ?>/>
132
  <?php _e('Don\'t autoptimize CSS outside the head-section. If the cache gets big, you might want to enable this.','autoptimize'); ?></label></td>
133
  </tr>
134
  <tr valign="top" class="hidden ao_adv">
135
+ <th scope="row"><?php _e('Defer CSS loading?','autoptimize'); ?></th>
136
+ <td><label for="autoptimize_css_defer"><input type="checkbox" name="autoptimize_css_defer" id="autoptimize_css_defer" <?php echo get_option('autoptimize_css_defer')?'checked="checked" ':''; ?>/>
137
+ <?php _e('Load optimized CSS only after page load (disables CSS inlining). <strong>Warning</strong>: <a href="http://wordpress.org/plugins/autoptimize/faq/" target="_blank">check the FAQ</a> before activating this option!','autoptimize'); ?></label></td>
138
+ </tr>
139
+ <tr valign="top" class="hidden ao_adv">
140
+ <th scope="row"><?php _e('Inline all CSS?','autoptimize'); ?></th>
141
+ <td><label for="autoptimize_css_inline"><input type="checkbox" id="autoptimize_css_inline" name="autoptimize_css_inline" <?php echo get_option('autoptimize_css_inline')?'checked="checked" ':''; ?>/>
142
+ <?php _e('Inlining all CSS can improve performance for sites with a low pageviews/ visitor-rate, but may slow down performance otherwise. CSS inlining disables CSS deferring.','autoptimize'); ?></label></td>
143
+ </tr>
144
+ <tr valign="top" class="hidden ao_adv">
145
+ <th scope="row"><?php _e('Exclude CSS from Autoptimize:','autoptimize'); ?></th>
146
+ <td><label for="autoptimize_css_exclude"><input type="text" style="width:100%;" name="autoptimize_css_exclude" value="<?php echo get_option('autoptimize_css_exclude','admin-bar.min.css, dashicons.min.css'); ?>"/><br />
147
+ <?php _e('A comma-seperated list of CSS you want to exclude from being optimized.','autoptimize'); ?></label></td>
148
  </tr>
149
  </table>
150
 
153
  <tr valign="top">
154
  <th scope="row"><?php _e('CDN Base URL','autoptimize'); ?></th>
155
  <td><label for="autoptimize_url"><input id="cdn_url" type="url" name="autoptimize_cdn_url" pattern="^(https?:)?\/\/([\da-z\.-]+)\.([\da-z\.]{2,6})([\/\w \.-]*)*\/?$" style="width:100%" value="<?php $it = get_option('autoptimize_cdn_url','');echo htmlentities($it); ?>" /><br />
156
+ <?php _e('Enter your CDN blog root directory URL if you want to enable CDN for images referenced in the CSS.','autoptimize'); ?></label></td>
157
  </tr>
158
  </table>
159
 
173
  </tr>
174
  <tr valign="top" class="hidden ao_adv">
175
  <th scope="row"><?php _e('Save aggregated script/css as static files?','autoptimize'); ?></th>
176
+ <td><label for="autoptimize_cache_nogzip"><input type="checkbox" name="autoptimize_cache_nogzip" <?php echo get_option('autoptimize_cache_nogzip','1')?'checked="checked" ':''; ?>/>
177
+ <?php _e('By default files saved are static css/js, uncheck this option if your webserver doesn\'t properly handle the compression and expiry.','autoptimize'); ?></label></td>
178
  </tr>
179
  </table>
180
  <input type="hidden" id="autoptimize_show_adv" name="autoptimize_show_adv" value="<?php echo get_option('autoptimize_show_adv','0'); ?>">
181
 
182
  <p class="submit">
183
+ <input type="submit" class="button-secondary" value="<?php _e('Save Changes','autoptimize') ?>" />
184
+ <input type="submit" class="button-primary" name="autoptimize_cache_clean" value="<?php _e('Save Changes and Empty Cache','autoptimize') ?>" />
185
  </p>
186
 
187
  </form>
223
  jQuery( "input#autoptimize_show_adv" ).val("0");
224
  });
225
 
226
+ jQuery( "#autoptimize_css_inline" ).change(function() {
227
+ if (this.checked) {
228
+ jQuery("#autoptimize_css_defer").prop("checked",false);
229
+ }
230
+ });
231
+
232
+ jQuery( "#autoptimize_css_defer" ).change(function() {
233
+ if (this.checked) {
234
+ jQuery("#autoptimize_css_inline").prop("checked",false);
235
+ }
236
+ });
237
+
238
  jQuery("#feed_dropdown").change(function() { show_feed(jQuery("#feed_dropdown").val()) });
239
  feedid=jQuery.cookie(cookiename);
240
  if(typeof(feedid) !== "string") feedid=1;
288
  register_setting('autoptimize','autoptimize_css_justhead');
289
  register_setting('autoptimize','autoptimize_css_datauris');
290
  register_setting('autoptimize','autoptimize_css_defer');
291
+ register_setting('autoptimize','autoptimize_css_inline');
292
  register_setting('autoptimize','autoptimize_cdn_url');
293
  register_setting('autoptimize','autoptimize_cache_clean');
294
  register_setting('autoptimize','autoptimize_cache_nogzip');
334
  'autoptimize_js_justhead' => 0,
335
  'autoptimize_js_forcehead' => 0,
336
  'autoptimize_css' => 0,
337
+ 'autoptimize_css_exclude' => "admin-bar.min.css, dashicons.min.css",
338
  'autoptimize_css_justhead' => 0,
339
  'autoptimize_css_defer' => 0,
340
+ 'autoptimize_css_inline' => 0,
341
  'autoptimize_css_datauris' => 0,
342
  'autoptimize_cdn_url' => "",
343
+ 'autoptimize_cache_nogzip' => 1,
344
  'autoptimize_show_adv' => 0
345
  );
346
 
classes/autoptimizeHTML.php CHANGED
@@ -2,8 +2,7 @@
2
 
3
  if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
4
 
5
- class autoptimizeHTML extends autoptimizeBase
6
- {
7
  private $keepcomments = false;
8
 
9
  //Does nothing
@@ -26,7 +25,11 @@ class autoptimizeHTML extends autoptimizeBase
26
 
27
  // Minify html
28
  $options = array('keepComments' => $this->keepcomments);
29
- $this->content = Minify_HTML::minify($this->content,$options);
 
 
 
 
30
 
31
  // restore noptimize
32
  $this->content = $this->restore_noptimize($this->content);
@@ -49,4 +52,4 @@ class autoptimizeHTML extends autoptimizeBase
49
  {
50
  return $this->content;
51
  }
52
- }
2
 
3
  if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
4
 
5
+ class autoptimizeHTML extends autoptimizeBase {
 
6
  private $keepcomments = false;
7
 
8
  //Does nothing
25
 
26
  // Minify html
27
  $options = array('keepComments' => $this->keepcomments);
28
+ $tmp_content = Minify_HTML::minify($this->content,$options);
29
+ if (!empty($tmp_content)) {
30
+ $this->content = $tmp_content;
31
+ unset($tmp_content);
32
+ }
33
 
34
  // restore noptimize
35
  $this->content = $this->restore_noptimize($this->content);
52
  {
53
  return $this->content;
54
  }
55
+ }
classes/autoptimizeScripts.php CHANGED
@@ -27,11 +27,15 @@ class autoptimizeScripts extends autoptimizeBase
27
  }
28
 
29
  $excludeJS = $options['js_exclude'];
 
 
30
  if ($excludeJS!=="") {
31
  $exclJSArr = array_filter(array_map('trim',explode(",",$excludeJS)));
32
  $this->dontmove = array_merge($exclJSArr,$this->dontmove);
33
  }
34
 
 
 
35
  //Should we add try-catch?
36
  if($options['trycatch'] == true)
37
  $this->trycatch = true;
@@ -47,76 +51,64 @@ class autoptimizeScripts extends autoptimizeBase
47
  $this->content = $this->hide_noptimize($this->content);
48
 
49
  //Save IE hacks
50
- $this->content = preg_replace('#(<\!--\[if.*\]>.*<\!\[endif\]-->)#Usie','\'%%IEHACK%%\'.base64_encode("$1").\'%%IEHACK%%\'',$this->content);
51
 
52
  //Get script files
53
- if(preg_match_all('#<script.*</script>#Usmi',$this->content,$matches))
54
- {
55
- foreach($matches[0] as $tag)
56
- {
57
- if(preg_match('#src=("|\')(.*)("|\')#Usmi',$tag,$source))
58
- {
59
  //External script
60
  $url = current(explode('?',$source[2],2));
61
  $path = $this->getpath($url);
62
- if($path !== false && preg_match('#\.js$#',$path))
63
- {
64
  //Inline
65
- if($this->ismergeable($tag))
66
- {
67
  //We can merge it
68
  $this->scripts[] = $path;
69
- }else{
70
  //No merge, but maybe we can move it
71
- if($this->ismovable($tag))
72
- {
73
  //Yeah, move it
74
- if($this->movetolast($tag))
75
- {
76
  $this->move['last'][] = $tag;
77
- }else{
78
  $this->move['first'][] = $tag;
79
  }
80
- }else{
81
  //We shouldn't touch this
82
  $tag = '';
83
  }
84
  }
85
- }else{
86
  //External script (example: google analytics)
87
  //OR Script is dynamic (.php etc)
88
- if($this->ismovable($tag))
89
- {
90
- if($this->movetolast($tag))
91
- {
92
  $this->move['last'][] = $tag;
93
- }else{
94
  $this->move['first'][] = $tag;
95
  }
96
- }else{
97
  //We shouldn't touch this
98
  $tag = '';
99
  }
100
  }
101
- }else{
102
  //Inline script
103
- if($this->ismergeable($tag))
104
- {
105
  preg_match('#<script.*>(.*)</script>#Usmi',$tag,$code);
106
  $code = preg_replace('#.*<!\[CDATA\[(?:\s*\*/)?(.*)(?://|/\*)\s*?\]\]>.*#sm','$1',$code[1]);
107
  $code = preg_replace('/(?:^\\s*<!--\\s*|\\s*(?:\\/\\/)?\\s*-->\\s*$)/','',$code);
108
  $this->scripts[] = 'INLINE;'.$code;
109
- }else{
110
  //Can we move this?
111
- if($this->ismovable($tag))
112
- {
113
- if($this->movetolast($tag))
114
- {
115
  $this->move['last'][] = $tag;
116
- }else{
117
  $this->move['first'][] = $tag;
118
  }
119
- }else{
120
  //We shouldn't touch this
121
  $tag = '';
122
  }
@@ -130,32 +122,30 @@ class autoptimizeScripts extends autoptimizeBase
130
  return true;
131
  }
132
 
133
- //No script files :(
134
  return false;
135
  }
136
 
137
  //Joins and optimizes JS
138
- public function minify()
139
- {
140
- foreach($this->scripts as $script)
141
- {
142
- if(preg_match('#^INLINE;#',$script))
143
- {
144
  //Inline script
145
  $script = preg_replace('#^INLINE;#','',$script);
146
  //Add try-catch?
147
- if($this->trycatch)
148
  $script = 'try{'.$script.'}catch(e){}';
 
149
  $this->jscode .= "\n".$script;
150
- }else{
151
  //External script
152
- if($script !== false && file_exists($script) && is_readable($script))
153
- {
154
  $script = file_get_contents($script);
155
  $script = preg_replace('/\x{EF}\x{BB}\x{BF}/','',$script);
156
  //Add try-catch?
157
- if($this->trycatch)
158
  $script = 'try{'.$script.'}catch(e){}';
 
159
  $this->jscode .= "\n".$script;
160
  }/*else{
161
  //Couldn't read JS. Maybe getpath isn't working?
@@ -166,19 +156,21 @@ class autoptimizeScripts extends autoptimizeBase
166
  //Check for already-minified code
167
  $this->md5hash = md5($this->jscode);
168
  $ccheck = new autoptimizeCache($this->md5hash,'js');
169
- if($ccheck->check())
170
- {
171
  $this->jscode = $ccheck->retrieve();
172
  return true;
173
  }
174
  unset($ccheck);
175
 
176
  //$this->jscode has all the uncompressed code now.
177
- if(class_exists('JSMin'))
178
- {
179
- $this->jscode = trim(JSMin::minify($this->jscode));
 
 
 
180
  return true;
181
- }else{
182
  return false;
183
  }
184
  }
@@ -187,8 +179,7 @@ class autoptimizeScripts extends autoptimizeBase
187
  public function cache()
188
  {
189
  $cache = new autoptimizeCache($this->md5hash,'js');
190
- if(!$cache->check())
191
- {
192
  //Cache our code
193
  $cache->cache($this->jscode,'text/javascript');
194
  }
@@ -197,11 +188,9 @@ class autoptimizeScripts extends autoptimizeBase
197
  }
198
 
199
  // Returns the content
200
- public function getcontent()
201
- {
202
  // Restore the full content
203
- if(!empty($this->restofcontent))
204
- {
205
  $this->content .= $this->restofcontent;
206
  $this->restofcontent = '';
207
  }
@@ -214,14 +203,22 @@ class autoptimizeScripts extends autoptimizeBase
214
  $replaceTag="</body>";
215
  $defer="defer ";
216
  }
 
 
217
 
218
  $bodyreplacement = implode('',$this->move['first']);
219
  $bodyreplacement .= '<script type="text/javascript" '.$defer.'src="'.$this->url.'"></script>';
220
  $bodyreplacement .= implode('',$this->move['last']).$replaceTag;
221
- $this->content = str_replace($replaceTag,$bodyreplacement,$this->content);
 
 
 
 
 
 
222
 
223
  // Restore IE hacks
224
- $this->content = preg_replace('#%%IEHACK%%(.*)%%IEHACK%%#Usie','stripslashes(base64_decode("$1"))',$this->content);
225
 
226
  // Restore noptimize
227
  $this->content = $this->restore_noptimize($this->content);
@@ -231,21 +228,20 @@ class autoptimizeScripts extends autoptimizeBase
231
  }
232
 
233
  //Checks agains the whitelist
234
- private function ismergeable($tag)
235
- {
236
- foreach($this->domove as $match)
237
- {
238
- if(strpos($tag,$match)!==false)
239
- {
240
  //Matched something
241
  return false;
242
  }
243
  }
244
 
245
- foreach($this->dontmove as $match)
246
- {
247
- if(strpos($tag,$match)!==false)
248
- {
 
 
249
  //Matched something
250
  return false;
251
  }
@@ -256,22 +252,20 @@ class autoptimizeScripts extends autoptimizeBase
256
  }
257
 
258
  //Checks agains the blacklist
259
- private function ismovable($tag)
260
- {
261
-
262
- foreach($this->domove as $match)
263
- {
264
- if(strpos($tag,$match)!==false)
265
- {
266
  //Matched something
267
  return true;
268
  }
269
  }
270
 
271
- foreach($this->dontmove as $match)
272
- {
273
- if(strpos($tag,$match)!==false)
274
- {
 
 
275
  //Matched something
276
  return false;
277
  }
@@ -281,12 +275,9 @@ class autoptimizeScripts extends autoptimizeBase
281
  return true;
282
  }
283
 
284
- private function movetolast($tag)
285
- {
286
- foreach($this->domovelast as $match)
287
- {
288
- if(strpos($tag,$match)!==false)
289
- {
290
  //Matched, return true
291
  return true;
292
  }
27
  }
28
 
29
  $excludeJS = $options['js_exclude'];
30
+ $excludeJS = apply_filters( 'autoptimize_filter_js_exclude', $excludeJS );
31
+
32
  if ($excludeJS!=="") {
33
  $exclJSArr = array_filter(array_map('trim',explode(",",$excludeJS)));
34
  $this->dontmove = array_merge($exclJSArr,$this->dontmove);
35
  }
36
 
37
+ $this->domovelast = apply_filters( 'autoptimize_filter_js_movelast', $this->domovelast );
38
+
39
  //Should we add try-catch?
40
  if($options['trycatch'] == true)
41
  $this->trycatch = true;
51
  $this->content = $this->hide_noptimize($this->content);
52
 
53
  //Save IE hacks
54
+ $this->content = $this->hide_iehacks($this->content);
55
 
56
  //Get script files
57
+ if(preg_match_all('#<script.*</script>#Usmi',$this->content,$matches)) {
58
+ foreach($matches[0] as $tag) {
59
+ if(preg_match('#src=("|\')(.*)("|\')#Usmi',$tag,$source)) {
 
 
 
60
  //External script
61
  $url = current(explode('?',$source[2],2));
62
  $path = $this->getpath($url);
63
+ if($path !== false && preg_match('#\.js$#',$path)) {
 
64
  //Inline
65
+ if($this->ismergeable($tag)) {
 
66
  //We can merge it
67
  $this->scripts[] = $path;
68
+ } else {
69
  //No merge, but maybe we can move it
70
+ if($this->ismovable($tag)) {
 
71
  //Yeah, move it
72
+ if($this->movetolast($tag)) {
 
73
  $this->move['last'][] = $tag;
74
+ } else {
75
  $this->move['first'][] = $tag;
76
  }
77
+ } else {
78
  //We shouldn't touch this
79
  $tag = '';
80
  }
81
  }
82
+ } else {
83
  //External script (example: google analytics)
84
  //OR Script is dynamic (.php etc)
85
+ if($this->ismovable($tag)) {
86
+ if($this->movetolast($tag)) {
 
 
87
  $this->move['last'][] = $tag;
88
+ } else {
89
  $this->move['first'][] = $tag;
90
  }
91
+ } else {
92
  //We shouldn't touch this
93
  $tag = '';
94
  }
95
  }
96
+ } else {
97
  //Inline script
98
+ if($this->ismergeable($tag)) {
 
99
  preg_match('#<script.*>(.*)</script>#Usmi',$tag,$code);
100
  $code = preg_replace('#.*<!\[CDATA\[(?:\s*\*/)?(.*)(?://|/\*)\s*?\]\]>.*#sm','$1',$code[1]);
101
  $code = preg_replace('/(?:^\\s*<!--\\s*|\\s*(?:\\/\\/)?\\s*-->\\s*$)/','',$code);
102
  $this->scripts[] = 'INLINE;'.$code;
103
+ } else {
104
  //Can we move this?
105
+ if($this->ismovable($tag)) {
106
+ if($this->movetolast($tag)) {
 
 
107
  $this->move['last'][] = $tag;
108
+ } else {
109
  $this->move['first'][] = $tag;
110
  }
111
+ } else {
112
  //We shouldn't touch this
113
  $tag = '';
114
  }
122
  return true;
123
  }
124
 
125
+ // No script files, great ;-)
126
  return false;
127
  }
128
 
129
  //Joins and optimizes JS
130
+ public function minify() {
131
+ foreach($this->scripts as $script) {
132
+ if(preg_match('#^INLINE;#',$script)) {
 
 
 
133
  //Inline script
134
  $script = preg_replace('#^INLINE;#','',$script);
135
  //Add try-catch?
136
+ if($this->trycatch) {
137
  $script = 'try{'.$script.'}catch(e){}';
138
+ }
139
  $this->jscode .= "\n".$script;
140
+ } else {
141
  //External script
142
+ if($script !== false && file_exists($script) && is_readable($script)) {
 
143
  $script = file_get_contents($script);
144
  $script = preg_replace('/\x{EF}\x{BB}\x{BF}/','',$script);
145
  //Add try-catch?
146
+ if($this->trycatch) {
147
  $script = 'try{'.$script.'}catch(e){}';
148
+ }
149
  $this->jscode .= "\n".$script;
150
  }/*else{
151
  //Couldn't read JS. Maybe getpath isn't working?
156
  //Check for already-minified code
157
  $this->md5hash = md5($this->jscode);
158
  $ccheck = new autoptimizeCache($this->md5hash,'js');
159
+ if($ccheck->check()) {
 
160
  $this->jscode = $ccheck->retrieve();
161
  return true;
162
  }
163
  unset($ccheck);
164
 
165
  //$this->jscode has all the uncompressed code now.
166
+ if(class_exists('JSMin')) {
167
+ $tmp_jscode = trim(JSMin::minify($this->jscode));
168
+ if (!empty($tmp_jscode)) {
169
+ $this->jscode = $tmp_jscode;
170
+ unset($tmp_jscode);
171
+ }
172
  return true;
173
+ } else {
174
  return false;
175
  }
176
  }
179
  public function cache()
180
  {
181
  $cache = new autoptimizeCache($this->md5hash,'js');
182
+ if(!$cache->check()) {
 
183
  //Cache our code
184
  $cache->cache($this->jscode,'text/javascript');
185
  }
188
  }
189
 
190
  // Returns the content
191
+ public function getcontent() {
 
192
  // Restore the full content
193
+ if(!empty($this->restofcontent)) {
 
194
  $this->content .= $this->restofcontent;
195
  $this->restofcontent = '';
196
  }
203
  $replaceTag="</body>";
204
  $defer="defer ";
205
  }
206
+
207
+ $defer = apply_filters( 'autoptimize_filter_js_defer', $defer );
208
 
209
  $bodyreplacement = implode('',$this->move['first']);
210
  $bodyreplacement .= '<script type="text/javascript" '.$defer.'src="'.$this->url.'"></script>';
211
  $bodyreplacement .= implode('',$this->move['last']).$replaceTag;
212
+
213
+ if (strpos($this->content,$replaceTag)!== false) {
214
+ $this->content = str_replace($replaceTag,$bodyreplacement,$this->content);
215
+ } else {
216
+ $this->content .= $bodyreplacement;
217
+ $this->warn_html();
218
+ }
219
 
220
  // Restore IE hacks
221
+ $this->content = $this->restore_iehacks($this->content);
222
 
223
  // Restore noptimize
224
  $this->content = $this->restore_noptimize($this->content);
228
  }
229
 
230
  //Checks agains the whitelist
231
+ private function ismergeable($tag) {
232
+ foreach($this->domove as $match) {
233
+ if(strpos($tag,$match)!==false) {
 
 
 
234
  //Matched something
235
  return false;
236
  }
237
  }
238
 
239
+ if ($this->movetolast($tag)) {
240
+ return false;
241
+ }
242
+
243
+ foreach($this->dontmove as $match) {
244
+ if(strpos($tag,$match)!==false) {
245
  //Matched something
246
  return false;
247
  }
252
  }
253
 
254
  //Checks agains the blacklist
255
+ private function ismovable($tag) {
256
+ foreach($this->domove as $match) {
257
+ if(strpos($tag,$match)!==false) {
 
 
 
 
258
  //Matched something
259
  return true;
260
  }
261
  }
262
 
263
+ if ($this->movetolast($tag)) {
264
+ return true;
265
+ }
266
+
267
+ foreach($this->dontmove as $match) {
268
+ if(strpos($tag,$match)!==false) {
269
  //Matched something
270
  return false;
271
  }
275
  return true;
276
  }
277
 
278
+ private function movetolast($tag) {
279
+ foreach($this->domovelast as $match) {
280
+ if(strpos($tag,$match)!==false) {
 
 
 
281
  //Matched, return true
282
  return true;
283
  }
classes/autoptimizeStyles.php CHANGED
@@ -1,8 +1,7 @@
1
  <?php
2
  if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
3
 
4
- class autoptimizeStyles extends autoptimizeBase
5
- {
6
  private $css = array();
7
  private $csscode = array();
8
  private $url = array();
@@ -12,11 +11,9 @@ class autoptimizeStyles extends autoptimizeBase
12
  private $hashmap = array();
13
 
14
  //Reads the page and collects style tags
15
- public function read($options)
16
- {
17
  //Remove everything that's not the header
18
- if($options['justhead'] == true)
19
- {
20
  $content = explode('</head>',$this->content,2);
21
  $this->content = $content[0].'</head>';
22
  $this->restofcontent = $content[1];
@@ -24,6 +21,7 @@ class autoptimizeStyles extends autoptimizeBase
24
 
25
  // what CSS shouldn't be autoptimized
26
  $excludeCSS = $options['css_exclude'];
 
27
  if ($excludeCSS!=="") {
28
  $this->dontmove = array_filter(array_map('trim',explode(",",$excludeCSS)));
29
  }
@@ -31,6 +29,9 @@ class autoptimizeStyles extends autoptimizeBase
31
  // should we defer css?
32
  $this->defer = $options['defer'];
33
 
 
 
 
34
  // get cdn url
35
  $this->cdn_url = $options['cdn_url'];
36
 
@@ -39,109 +40,104 @@ class autoptimizeStyles extends autoptimizeBase
39
 
40
  // noptimize me
41
  $this->content = $this->hide_noptimize($this->content);
 
 
 
 
 
 
 
 
 
 
 
 
42
 
43
- //Save IE hacks
44
- $this->content = preg_replace('#(<\!--\[if.*\]>.*<\!\[endif\]-->)#Usie','\'%%IEHACK%%\'.base64_encode("$1").\'%%IEHACK%%\'',$this->content);
45
 
46
- //Get <style> and <link>
47
- if(preg_match_all('#(<style[^>]*>.*</style>)|(<link[^>]*stylesheet[^>]*>)#Usmi',$this->content,$matches))
48
- {
49
- foreach($matches[0] as $tag)
50
- {
51
  if ($this->ismovable($tag)) {
 
 
 
 
 
 
 
 
 
 
 
 
 
52
 
53
- // Get the media
54
- if(strpos($tag,'media=')!==false)
55
- {
56
- preg_match('#media=(?:"|\')([^>]*)(?:"|\')#Ui',$tag,$medias);
57
- $medias = explode(',',$medias[1]);
58
- $media = array();
59
- foreach($medias as $elem)
60
- {
61
- // $media[] = current(explode(' ',trim($elem),2));
62
- $media[] = $elem;
 
 
 
 
 
 
 
63
  }
64
- }else{
65
- //No media specified - applies to all
66
- $media = array('all');
67
- }
68
-
69
- if(preg_match('#<link.*href=("|\')(.*)("|\')#Usmi',$tag,$source))
70
- {
71
- //<link>
72
- $url = current(explode('?',$source[2],2));
73
- $path = $this->getpath($url);
74
 
75
- if($path !==false && preg_match('#\.css$#',$path))
76
- {
77
- //Good link
78
- $this->css[] = array($media,$path);
79
- }else{
80
- //Link is dynamic (.php etc)
81
- $tag = '';
82
- }
83
- }else{
84
- //<style>
85
- preg_match('#<style.*>(.*)</style>#Usmi',$tag,$code);
86
- $code = preg_replace('#^.*<!\[CDATA\[(?:\s*\*/)?(.*)(?://|/\*)\s*?\]\]>.*$#sm','$1',$code[1]);
87
- $this->css[] = array($media,'INLINE;'.$code);
88
- }
89
-
90
- //Remove the original style tag
91
- $this->content = str_replace($tag,'',$this->content);
92
  }
93
  }
94
-
95
  return true;
96
  }
97
-
98
- //No styles :(
99
  return false;
100
  }
101
 
102
- //Joins and optimizes CSS
103
- public function minify()
104
- {
105
- foreach($this->css as $group)
106
- {
107
  list($media,$css) = $group;
108
- if(preg_match('#^INLINE;#',$css))
109
- {
110
  //<style>
111
  $css = preg_replace('#^INLINE;#','',$css);
112
  $css = $this->fixurls(ABSPATH.'/index.php',$css);
113
- }else{
114
  //<link>
115
- if($css !== false && file_exists($css) && is_readable($css))
116
- {
117
  $css = $this->fixurls($css,file_get_contents($css));
118
  $css = preg_replace('/\x{EF}\x{BB}\x{BF}/','',$css);
119
- }else{
120
  //Couldn't read CSS. Maybe getpath isn't working?
121
  $css = '';
122
  }
123
  }
124
 
125
- foreach($media as $elem)
126
- {
127
  if(!isset($this->csscode[$elem]))
128
  $this->csscode[$elem] = '';
129
  $this->csscode[$elem] .= "\n/*FILESTART*/".$css;
130
  }
131
  }
132
 
133
- //Check for duplicate code
134
  $md5list = array();
135
  $tmpcss = $this->csscode;
136
- foreach($tmpcss as $media => $code)
137
- {
138
  $md5sum = md5($code);
139
  $medianame = $media;
140
- foreach($md5list as $med => $sum)
141
- {
142
  //If same code
143
- if($sum === $md5sum)
144
- {
145
  //Add the merged code
146
  $medianame = $med.', '.$media;
147
  $this->csscode[$medianame] = $code;
@@ -155,23 +151,27 @@ class autoptimizeStyles extends autoptimizeBase
155
  unset($tmpcss);
156
 
157
  //Manage @imports, while is for recursive import management
158
- foreach($this->csscode as &$thiscss)
159
- {
160
- //Flag to trigger import reconstitution
161
  $fiximports = false;
162
- while(preg_match_all('#@import.*(?:;|$)#Um',$thiscss,$matches))
163
- {
164
- foreach($matches[0] as $import)
165
- {
166
  $url = trim(preg_replace('#^.*((?:https?|ftp)://.*\.css).*$#','$1',$import)," \t\n\r\0\x0B\"'");
167
  $path = $this->getpath($url);
168
- $import_ok=false;
169
  if (file_exists($path) && is_readable($path)) {
170
  $code = addcslashes($this->fixurls($path,file_get_contents($path)),"\\");
171
  $code = preg_replace('/\x{EF}\x{BB}\x{BF}/','',$code);
172
  if(!empty($code)) {
173
- $thiscss = preg_replace('#(/\*FILESTART\*/.*)'.preg_quote($import,'#').'#Us','/*FILESTART2*/'.$code.'$1',$thiscss);
174
- $import_ok=true;
 
 
 
 
 
175
  }
176
  }
177
 
@@ -187,52 +187,44 @@ class autoptimizeStyles extends autoptimizeBase
187
  }
188
 
189
  // add external imports to top of aggregated CSS
190
- if($fiximports)
191
- {
192
  $thiscss=$external_imports.$thiscss;
193
  }
194
  }
195
  unset($thiscss);
196
 
197
- //$this->csscode has all the uncompressed code now.
198
  $mhtmlcount = 0;
199
- foreach($this->csscode as &$code)
200
- {
201
- //Check for already-minified code
202
  $hash = md5($code);
203
  $ccheck = new autoptimizeCache($hash,'css');
204
- if($ccheck->check())
205
- {
206
  $code = $ccheck->retrieve();
207
  $this->hashmap[md5($code)] = $hash;
208
  continue;
209
  }
210
- unset($ccheck);
211
-
212
  //Do the imaging!
213
  $imgreplace = array();
214
  preg_match_all('#(background[^;}]*url\((?!data)(.*)\)[^;}]*)(?:;|$|})#Usm',$code,$matches);
215
 
216
- if(($this->datauris == true) && (function_exists('base64_encode')) && (is_array($matches)))
217
- {
218
- foreach($matches[2] as $count => $quotedurl)
219
- {
220
  $url = trim($quotedurl," \t\n\r\0\x0B\"'");
221
 
222
- // fgo: if querystring, remove it from url
223
  if (strpos($url,'?') !== false) { $url = reset(explode('?',$url)); }
224
 
225
  $path = $this->getpath($url);
226
 
227
- // fgo: jpe?j should be jpe?g I guess + 5KB seems like a lot, lower to 2.5KB
228
- if($path != false && preg_match('#\.(jpe?g|png|gif|bmp)$#',$path) && file_exists($path) && is_readable($path) && filesize($path) <= 2560)
229
- {
230
- //It's an image
231
- //Get type
232
  $type=end(explode('.',$path));
233
- switch($type)
234
- {
235
- // fgo: jpeg and jpg
236
  case 'jpeg':
237
  $dataurihead = 'data:image/jpeg;base64,';
238
  break;
@@ -265,8 +257,7 @@ class autoptimizeStyles extends autoptimizeBase
265
  }
266
  } else if ((is_array($matches)) && (!empty($this->cdn_url))) {
267
  // change background image urls to cdn-url
268
- foreach($matches[2] as $count => $quotedurl)
269
- {
270
  $url = trim($quotedurl," \t\n\r\0\x0B\"'");
271
  $cdn_url=$this->url_replace_cdn($url);
272
  $imgreplace[$matches[1][$count]] = str_replace($quotedurl,$cdn_url,$matches[1][$count]);
@@ -287,7 +278,7 @@ class autoptimizeStyles extends autoptimizeBase
287
  }
288
 
289
  if (!empty($tmp_code)) {
290
- $code=$tmp_code;
291
  unset($tmp_code);
292
  }
293
 
@@ -298,16 +289,13 @@ class autoptimizeStyles extends autoptimizeBase
298
  }
299
 
300
  //Caches the CSS in uncompressed, deflated and gzipped form.
301
- public function cache()
302
- {
303
- if($this->datauris)
304
- {
305
- //MHTML Preparation
306
  $this->mhtml = "/*\r\nContent-Type: multipart/related; boundary=\"_\"\r\n\r\n".$this->mhtml."*/\r\n";
307
  $md5 = md5($this->mhtml);
308
  $cache = new autoptimizeCache($md5,'txt');
309
- if(!$cache->check())
310
- {
311
  //Cache our images for IE
312
  $cache->cache($this->mhtml,'text/plain');
313
  }
@@ -315,22 +303,17 @@ class autoptimizeStyles extends autoptimizeBase
315
  }
316
 
317
  //CSS cache
318
- foreach($this->csscode as $media => $code)
319
- {
320
- // fgo, moved from below to prevent empty md5 resulting in filenames without hash autoptimize_.php
321
  $md5 = $this->hashmap[md5($code)];
322
 
323
- if($this->datauris)
324
- {
325
- //Images for ie! Get the right url
326
  $code = str_replace('%%MHTML%%',$mhtml,$code);
327
  }
328
-
329
- // $md5 = $this->hashmap[md5($code)];
330
  $cache = new autoptimizeCache($md5,'css');
331
- if(!$cache->check())
332
- {
333
- //Cache our code
334
  $cache->cache($code,'text/css');
335
  }
336
  $this->url[$media] = AUTOPTIMIZE_CACHE_URL.$cache->getname();
@@ -338,48 +321,84 @@ class autoptimizeStyles extends autoptimizeBase
338
  }
339
 
340
  //Returns the content
341
- public function getcontent()
342
- {
343
  //Restore IE hacks
344
- // fgo: added stripslashes as e modifier escapes stuff
345
- $this->content = preg_replace('#%%IEHACK%%(.*)%%IEHACK%%#Usie','stripslashes(base64_decode("$1"))',$this->content);
 
 
 
 
 
 
 
 
 
 
 
 
346
  // restore noptimize
347
  $this->content = $this->restore_noptimize($this->content);
 
348
  //Restore the full content
349
- if(!empty($this->restofcontent))
350
- {
351
  $this->content .= $this->restofcontent;
352
  $this->restofcontent = '';
353
  }
354
 
355
- if($this->defer == true) {
356
- $deferredCssBlock = "<script>function lCss(url,media) {var d=document;var l=d.createElement('link');l.rel='stylesheet';l.type='text/css';l.href=url;l.media=media; d.getElementsByTagName('head')[0].appendChild(l);}function deferredCSS() {";
357
- }
358
-
359
  //Add the new stylesheets
360
- foreach($this->url as $media => $url)
361
- {
362
- $url = $this->url_replace_cdn($url);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
363
 
364
- //Add the stylesheet either deferred (import at bottom) or normal links in head
365
  if($this->defer == true) {
366
- $deferredCssBlock .= "lCss('".$url."','".$media."');";
367
- } else {
368
- $this->content = str_replace('<title>','<link type="text/css" media="'.$media.'" href="'.$url.'" rel="stylesheet" /><title>',$this->content);
 
 
 
 
369
  }
370
  }
371
-
372
- if($this->defer == true) {
373
- $deferredCssBlock .= "}if(window.addEventListener){window.addEventListener('DOMContentLoaded',deferredCSS,false);}else{window.onload = deferredCSS;}</script>";
374
- $this->content = str_replace('</body>',$deferredCssBlock.'</body>',$this->content);
375
  }
376
 
377
  //Return the modified stylesheet
378
  return $this->content;
379
  }
380
 
381
- private function fixurls($file,$code)
382
- {
383
  // $file = str_replace(ABSPATH,'/',$file); //Sth like /wp-content/file.css
384
  $file = str_replace(WP_ROOT_DIR,'/',$file);
385
  $dir = dirname($file); //Like /wp-content
@@ -387,7 +406,7 @@ class autoptimizeStyles extends autoptimizeBase
387
  // quick fix for import-troubles in e.g. arras theme
388
  $code=preg_replace('#@import ("|\')(.+?)\.css("|\')#','@import url("${2}.css")',$code);
389
 
390
- if(preg_match_all('#url?\((?!data)(.*)\)#Usi',$code,$matches))
391
  {
392
  $replace = array();
393
  foreach($matches[1] as $k => $url)
@@ -414,13 +433,10 @@ class autoptimizeStyles extends autoptimizeBase
414
  return $code;
415
  }
416
 
417
- private function ismovable($tag)
418
- {
419
  if (is_array($this->dontmove)) {
420
- foreach($this->dontmove as $match)
421
- {
422
- if(strpos($tag,$match)!==false)
423
- {
424
  //Matched something
425
  return false;
426
  }
1
  <?php
2
  if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
3
 
4
+ class autoptimizeStyles extends autoptimizeBase {
 
5
  private $css = array();
6
  private $csscode = array();
7
  private $url = array();
11
  private $hashmap = array();
12
 
13
  //Reads the page and collects style tags
14
+ public function read($options) {
 
15
  //Remove everything that's not the header
16
+ if($options['justhead'] == true) {
 
17
  $content = explode('</head>',$this->content,2);
18
  $this->content = $content[0].'</head>';
19
  $this->restofcontent = $content[1];
21
 
22
  // what CSS shouldn't be autoptimized
23
  $excludeCSS = $options['css_exclude'];
24
+ $excludeCSS = apply_filters( 'autoptimize_filter_css_exclude', $excludeCSS );
25
  if ($excludeCSS!=="") {
26
  $this->dontmove = array_filter(array_map('trim',explode(",",$excludeCSS)));
27
  }
29
  // should we defer css?
30
  $this->defer = $options['defer'];
31
 
32
+ // should we inline?
33
+ $this->inline = $options['inline'];
34
+
35
  // get cdn url
36
  $this->cdn_url = $options['cdn_url'];
37
 
40
 
41
  // noptimize me
42
  $this->content = $this->hide_noptimize($this->content);
43
+
44
+ // exclude noscript, as those may contain CSS
45
+ if ( strpos( $this->content, '<noscript>' ) !== false ) {
46
+ $this->content = preg_replace_callback(
47
+ '#<noscript>.*?</noscript>#is',
48
+ create_function(
49
+ '$matches',
50
+ 'return "%%NOSCRIPT%%".base64_encode($matches[0])."%%NOSCRIPT%%";'
51
+ ),
52
+ $this->content
53
+ );
54
+ }
55
 
56
+ // Save IE hacks
57
+ $this->content = $this->hide_iehacks($this->content);
58
 
59
+ // Get <style> and <link>
60
+ if(preg_match_all('#(<style[^>]*>.*</style>)|(<link[^>]*stylesheet[^>]*>)#Usmi',$this->content,$matches)) {
61
+ foreach($matches[0] as $tag) {
 
 
62
  if ($this->ismovable($tag)) {
63
+ // Get the media
64
+ if(strpos($tag,'media=')!==false) {
65
+ preg_match('#media=(?:"|\')([^>]*)(?:"|\')#Ui',$tag,$medias);
66
+ $medias = explode(',',$medias[1]);
67
+ $media = array();
68
+ foreach($medias as $elem) {
69
+ // $media[] = current(explode(' ',trim($elem),2));
70
+ $media[] = $elem;
71
+ }
72
+ } else {
73
+ //No media specified - applies to all
74
+ $media = array('all');
75
+ }
76
 
77
+ if(preg_match('#<link.*href=("|\')(.*)("|\')#Usmi',$tag,$source)) {
78
+ //<link>
79
+ $url = current(explode('?',$source[2],2));
80
+ $path = $this->getpath($url);
81
+
82
+ if($path !==false && preg_match('#\.css$#',$path)) {
83
+ //Good link
84
+ $this->css[] = array($media,$path);
85
+ }else{
86
+ //Link is dynamic (.php etc)
87
+ $tag = '';
88
+ }
89
+ } else {
90
+ //<style>
91
+ preg_match('#<style.*>(.*)</style>#Usmi',$tag,$code);
92
+ $code = preg_replace('#^.*<!\[CDATA\[(?:\s*\*/)?(.*)(?://|/\*)\s*?\]\]>.*$#sm','$1',$code[1]);
93
+ $this->css[] = array($media,'INLINE;'.$code);
94
  }
 
 
 
 
 
 
 
 
 
 
95
 
96
+ //Remove the original style tag
97
+ $this->content = str_replace($tag,'',$this->content);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
98
  }
99
  }
 
100
  return true;
101
  }
102
+ // Really, no styles?
 
103
  return false;
104
  }
105
 
106
+ // Joins and optimizes CSS
107
+ public function minify() {
108
+ foreach($this->css as $group) {
 
 
109
  list($media,$css) = $group;
110
+ if(preg_match('#^INLINE;#',$css)) {
 
111
  //<style>
112
  $css = preg_replace('#^INLINE;#','',$css);
113
  $css = $this->fixurls(ABSPATH.'/index.php',$css);
114
+ } else {
115
  //<link>
116
+ if($css !== false && file_exists($css) && is_readable($css)) {
 
117
  $css = $this->fixurls($css,file_get_contents($css));
118
  $css = preg_replace('/\x{EF}\x{BB}\x{BF}/','',$css);
119
+ } else {
120
  //Couldn't read CSS. Maybe getpath isn't working?
121
  $css = '';
122
  }
123
  }
124
 
125
+ foreach($media as $elem) {
 
126
  if(!isset($this->csscode[$elem]))
127
  $this->csscode[$elem] = '';
128
  $this->csscode[$elem] .= "\n/*FILESTART*/".$css;
129
  }
130
  }
131
 
132
+ // Check for duplicate code
133
  $md5list = array();
134
  $tmpcss = $this->csscode;
135
+ foreach($tmpcss as $media => $code) {
 
136
  $md5sum = md5($code);
137
  $medianame = $media;
138
+ foreach($md5list as $med => $sum) {
 
139
  //If same code
140
+ if($sum === $md5sum) {
 
141
  //Add the merged code
142
  $medianame = $med.', '.$media;
143
  $this->csscode[$medianame] = $code;
151
  unset($tmpcss);
152
 
153
  //Manage @imports, while is for recursive import management
154
+ foreach($this->csscode as &$thiscss) {
155
+ // Flag to trigger import reconstitution and var to hold external imports
 
156
  $fiximports = false;
157
+ $external_imports = "";
158
+
159
+ while(preg_match_all('#^(/*\s?)@import.*(?:;|$)#Um',$thiscss,$matches)) {
160
+ foreach($matches[0] as $import) {
161
  $url = trim(preg_replace('#^.*((?:https?|ftp)://.*\.css).*$#','$1',$import)," \t\n\r\0\x0B\"'");
162
  $path = $this->getpath($url);
163
+ $import_ok = false;
164
  if (file_exists($path) && is_readable($path)) {
165
  $code = addcslashes($this->fixurls($path,file_get_contents($path)),"\\");
166
  $code = preg_replace('/\x{EF}\x{BB}\x{BF}/','',$code);
167
  if(!empty($code)) {
168
+ $tmp_thiscss = preg_replace('#(/\*FILESTART\*/.*)'.preg_quote($import,'#').'#Us','/*FILESTART2*/'.$code.'$1',$thiscss);
169
+ if (!empty($tmp_thiscss)) {
170
+ $thiscss = $tmp_thiscss;
171
+ $import_ok = true;
172
+ unset($tmp_thiscss);
173
+ }
174
+ unset($code);
175
  }
176
  }
177
 
187
  }
188
 
189
  // add external imports to top of aggregated CSS
190
+ if($fiximports) {
 
191
  $thiscss=$external_imports.$thiscss;
192
  }
193
  }
194
  unset($thiscss);
195
 
196
+ // $this->csscode has all the uncompressed code now.
197
  $mhtmlcount = 0;
198
+ foreach($this->csscode as &$code) {
199
+ // Check for already-minified code
 
200
  $hash = md5($code);
201
  $ccheck = new autoptimizeCache($hash,'css');
202
+ if($ccheck->check()) {
 
203
  $code = $ccheck->retrieve();
204
  $this->hashmap[md5($code)] = $hash;
205
  continue;
206
  }
207
+ unset($ccheck);
 
208
  //Do the imaging!
209
  $imgreplace = array();
210
  preg_match_all('#(background[^;}]*url\((?!data)(.*)\)[^;}]*)(?:;|$|})#Usm',$code,$matches);
211
 
212
+ if(($this->datauris == true) && (function_exists('base64_encode')) && (is_array($matches))) {
213
+ foreach($matches[2] as $count => $quotedurl) {
 
 
214
  $url = trim($quotedurl," \t\n\r\0\x0B\"'");
215
 
216
+ // if querystring, remove it from url
217
  if (strpos($url,'?') !== false) { $url = reset(explode('?',$url)); }
218
 
219
  $path = $this->getpath($url);
220
 
221
+ $datauri_max_size = 2560;
222
+ $datauri_max_size = (int) apply_filters( 'autoptimize_filter_css_datauri_maxsize', $datauri_max_size );
223
+
224
+ if($path != false && preg_match('#\.(jpe?g|png|gif|bmp)$#',$path) && file_exists($path) && is_readable($path) && filesize($path) <= $datauri_max_size) {
225
+ //It's an image, get the type
226
  $type=end(explode('.',$path));
227
+ switch($type) {
 
 
228
  case 'jpeg':
229
  $dataurihead = 'data:image/jpeg;base64,';
230
  break;
257
  }
258
  } else if ((is_array($matches)) && (!empty($this->cdn_url))) {
259
  // change background image urls to cdn-url
260
+ foreach($matches[2] as $count => $quotedurl) {
 
261
  $url = trim($quotedurl," \t\n\r\0\x0B\"'");
262
  $cdn_url=$this->url_replace_cdn($url);
263
  $imgreplace[$matches[1][$count]] = str_replace($quotedurl,$cdn_url,$matches[1][$count]);
278
  }
279
 
280
  if (!empty($tmp_code)) {
281
+ $code = $tmp_code;
282
  unset($tmp_code);
283
  }
284
 
289
  }
290
 
291
  //Caches the CSS in uncompressed, deflated and gzipped form.
292
+ public function cache() {
293
+ if($this->datauris) {
294
+ // MHTML Preparation
 
 
295
  $this->mhtml = "/*\r\nContent-Type: multipart/related; boundary=\"_\"\r\n\r\n".$this->mhtml."*/\r\n";
296
  $md5 = md5($this->mhtml);
297
  $cache = new autoptimizeCache($md5,'txt');
298
+ if(!$cache->check()) {
 
299
  //Cache our images for IE
300
  $cache->cache($this->mhtml,'text/plain');
301
  }
303
  }
304
 
305
  //CSS cache
306
+ foreach($this->csscode as $media => $code) {
 
 
307
  $md5 = $this->hashmap[md5($code)];
308
 
309
+ if($this->datauris) {
310
+ // Images for ie! Get the right url
 
311
  $code = str_replace('%%MHTML%%',$mhtml,$code);
312
  }
313
+
 
314
  $cache = new autoptimizeCache($md5,'css');
315
+ if(!$cache->check()) {
316
+ // Cache our code
 
317
  $cache->cache($code,'text/css');
318
  }
319
  $this->url[$media] = AUTOPTIMIZE_CACHE_URL.$cache->getname();
321
  }
322
 
323
  //Returns the content
324
+ public function getcontent() {
 
325
  //Restore IE hacks
326
+ $this->content = $this->restore_iehacks($this->content);
327
+
328
+ // restore noscript
329
+ if ( strpos( $this->content, '%%NOSCRIPT%%' ) !== false ) {
330
+ $this->content = preg_replace_callback(
331
+ '#%%NOSCRIPT%%(.*?)%%NOSCRIPT%%#is',
332
+ create_function(
333
+ '$matches',
334
+ 'return stripslashes(base64_decode($matches[1]));'
335
+ ),
336
+ $this->content
337
+ );
338
+ }
339
+
340
  // restore noptimize
341
  $this->content = $this->restore_noptimize($this->content);
342
+
343
  //Restore the full content
344
+ if(!empty($this->restofcontent)) {
 
345
  $this->content .= $this->restofcontent;
346
  $this->restofcontent = '';
347
  }
348
 
349
+ $warn_html_template=false;
350
+
 
 
351
  //Add the new stylesheets
352
+ if ($this->inline == true) {
353
+ foreach($this->csscode as $media => $code) {
354
+ if (strpos($this->content,"<title>")!==false) {
355
+ $this->content = str_replace('<title>','<style type="text/css" media="'.$media.'">'.$code.'</style><title>',$this->content);
356
+ } else {
357
+ $warn_html_template=true;
358
+ $this->content .= '<style type="text/css" media="'.$media.'">'.$code.'</style>';
359
+ }
360
+ }
361
+ } else {
362
+ if($this->defer == true) {
363
+ $deferredCssBlock = "<script>function lCss(url,media) {var d=document;var l=d.createElement('link');l.rel='stylesheet';l.type='text/css';l.href=url;l.media=media; d.getElementsByTagName('head')[0].appendChild(l);}function deferredCSS() {";
364
+ }
365
+
366
+ foreach($this->url as $media => $url) {
367
+ $url = $this->url_replace_cdn($url);
368
+
369
+ //Add the stylesheet either deferred (import at bottom) or normal links in head
370
+ if($this->defer == true) {
371
+ $deferredCssBlock .= "lCss('".$url."','".$media."');";
372
+ } else {
373
+ if (strpos($this->content,"<title>")!==false) {
374
+ $this->content = str_replace('<title>','<link type="text/css" media="'.$media.'" href="'.$url.'" rel="stylesheet" /><title>',$this->content);
375
+ } else {
376
+ $warn_html_template=true;
377
+ $this->content .= '<link type="text/css" media="'.$media.'" href="'.$url.'" rel="stylesheet" />';
378
+ }
379
+ }
380
+ }
381
 
 
382
  if($this->defer == true) {
383
+ $deferredCssBlock .= "}if(window.addEventListener){window.addEventListener('DOMContentLoaded',deferredCSS,false);}else{window.onload = deferredCSS;}</script>";
384
+ if (strpos($this->content,"</body>")!==false) {
385
+ $this->content = str_replace('</body>',$deferredCssBlock.'</body>',$this->content);
386
+ } else {
387
+ $warn_html_template=true;
388
+ $this->content .= $deferredCssBlock;
389
+ }
390
  }
391
  }
392
+
393
+ if ($warn_html_template) {
394
+ $this->warn_html();
 
395
  }
396
 
397
  //Return the modified stylesheet
398
  return $this->content;
399
  }
400
 
401
+ private function fixurls($file,$code) {
 
402
  // $file = str_replace(ABSPATH,'/',$file); //Sth like /wp-content/file.css
403
  $file = str_replace(WP_ROOT_DIR,'/',$file);
404
  $dir = dirname($file); //Like /wp-content
406
  // quick fix for import-troubles in e.g. arras theme
407
  $code=preg_replace('#@import ("|\')(.+?)\.css("|\')#','@import url("${2}.css")',$code);
408
 
409
+ if(preg_match_all('#url\((?!data)(.*)\)#Usi',$code,$matches))
410
  {
411
  $replace = array();
412
  foreach($matches[1] as $k => $url)
433
  return $code;
434
  }
435
 
436
+ private function ismovable($tag) {
 
437
  if (is_array($this->dontmove)) {
438
+ foreach($this->dontmove as $match) {
439
+ if(strpos($tag,$match)!==false) {
 
 
440
  //Matched something
441
  return false;
442
  }
classes/external/php/{yui-php-cssmin-2.4.8-1.php → yui-php-cssmin-2.4.8-2.php} RENAMED
@@ -1,11 +1,11 @@
1
  <?php
2
 
3
  /*!
4
- * cssmin.php rev ebaf67b 12/06/2013
5
  * Author: Tubal Martin - http://tubalmartin.me/
6
  * Repo: https://github.com/tubalmartin/YUI-CSS-compressor-PHP-port
7
  *
8
- * This is a PHP port of the CSS minification tool distributed with YUICompressor,
9
  * itself a port of the cssmin utility by Isaac Schlueter - http://foohack.com/
10
  * Permission is hereby granted to use the PHP version under the same
11
  * conditions as the YUICompressor.
@@ -92,7 +92,7 @@ class CSSmin
92
  // preserve strings so their content doesn't get accidentally minified
93
  $css = preg_replace_callback('/(?:"(?:[^\\\\"]|\\\\.|\\\\)*")|'."(?:'(?:[^\\\\']|\\\\.|\\\\)*')/S", array($this, 'replace_string'), $css);
94
 
95
- // Let's divide css code in chunks of 25.000 chars aprox.
96
  // Reason: PHP's PCRE functions like preg_replace have a "backtrack limit"
97
  // of 100.000 chars by default (php < 5.3.7) so if we're dealing with really
98
  // long strings and a (sub)pattern matches a number of chars greater than
@@ -101,7 +101,7 @@ class CSSmin
101
  $charset = '';
102
  $charset_regexp = '/(@charset)( [^;]+;)/i';
103
  $css_chunks = array();
104
- $css_chunk_length = 25000; // aprox size, not exact
105
  $start_index = 0;
106
  $i = $css_chunk_length; // save initial iterations
107
  $l = strlen($css);
@@ -113,7 +113,7 @@ class CSSmin
113
  } else {
114
  // chunk css code securely
115
  while ($i < $l) {
116
- $i += 50; // save iterations. 500 checks for a closing curly brace }
117
  if ($l - $start_index <= $css_chunk_length || $i >= $l) {
118
  $css_chunks[] = $this->str_slice($css, $start_index);
119
  break;
@@ -264,6 +264,9 @@ class CSSmin
264
  // Normalize all whitespace strings to single spaces. Easier to work with that way.
265
  $css = preg_replace('/\s+/', ' ', $css);
266
 
 
 
 
267
  // Shorten & preserve calculations calc(...) since spaces are important
268
  $css = preg_replace_callback('/calc(\(((?:[^\(\)]+|(?1))*)\))/i', array($this, 'replace_calc'), $css);
269
 
@@ -289,7 +292,7 @@ class CSSmin
289
  // But, be careful not to turn "p :link {...}" into "p:link{...}"
290
  // Swap out any pseudo-class colons with the token, and then swap back.
291
  $css = preg_replace_callback('/(?:^|\})(?:(?:[^\{\:])+\:)+(?:[^\{]*\{)/', array($this, 'replace_colon'), $css);
292
-
293
  // Remove spaces before the things that should not have spaces before them.
294
  $css = preg_replace('/\s+([\!\{\}\;\:\>\+\(\)\]\~\=,])/', '$1', $css);
295
 
@@ -317,7 +320,7 @@ class CSSmin
317
  // lower case some common function that can be values
318
  // NOTE: rgb() isn't useful as we replace with #hex later, as well as and() is already done for us
319
  $css = preg_replace_callback('/([:,\( ]\s*)(attr|color-stop|from|rgba|to|url|(?:-(?:atsc|khtml|moz|ms|o|wap|webkit)-)?(?:calc|max|min|(?:repeating-)?(?:linear|radial)-gradient)|-webkit-gradient)/iS', array($this, 'lowercase_common_functions_values'), $css);
320
-
321
  // Put the space back in some cases, to support stuff like
322
  // @media screen and (-webkit-min-device-pixel-ratio:0){
323
  $css = preg_replace('/\band\(/i', 'and (', $css);
@@ -336,6 +339,9 @@ class CSSmin
336
  // Replace 0 length units 0(px,em,%) with 0.
337
  $css = preg_replace('/(^|[^0-9])(?:0?\.)?0(?:em|ex|ch|rem|vw|vh|vm|vmin|cm|mm|in|px|pt|pc|%|deg|g?rad|m?s|k?hz)/iS', '${1}0', $css);
338
 
 
 
 
339
  // Replace 0 0; or 0 0 0; or 0 0 0 0; with 0.
340
  $css = preg_replace('/\:0(?: 0){1,3}(;|\}| \!)/', ':0$1', $css);
341
 
@@ -373,6 +379,16 @@ class CSSmin
373
  // Add "/" back to fix Opera -o-device-pixel-ratio query
374
  $css = preg_replace('/'. self::QUERY_FRACTION .'/', '/', $css);
375
 
 
 
 
 
 
 
 
 
 
 
376
  // Some source control tools don't like it when files containing lines longer
377
  // than, say 8000 characters, are checked in. The linebreak option is used in
378
  // that case to split long lines after a specific column.
@@ -388,18 +404,8 @@ class CSSmin
388
  }
389
  }
390
 
391
- // Replace multiple semi-colons in a row by a single one
392
- // See SF bug #1980989
393
- $css = preg_replace('/;;+/', ';', $css);
394
-
395
- // Restore new lines for /*! important comments
396
- $css = preg_replace('/'. self::NL .'/', "\n", $css);
397
-
398
- // Lowercase all uppercase properties
399
- $css = preg_replace_callback('/(\{|\;)([A-Z\-]+)(\:)/', array($this, 'lowercase_properties'), $css);
400
-
401
- // restore preserved comments and strings
402
- for ($i = 0, $max = count($this->preserved_tokens); $i < $max; $i++) {
403
  $css = preg_replace('/' . self::TOKEN . $i . '___/', $this->preserved_tokens[$i], $css, 1);
404
  }
405
 
@@ -582,6 +588,17 @@ class CSSmin
582
  return 'calc('. self::TOKEN . (count($this->preserved_tokens) - 1) . '___' . ')';
583
  }
584
 
 
 
 
 
 
 
 
 
 
 
 
585
  private function rgb_to_hex($matches)
586
  {
587
  // Support for percentage values rgb(100%, 0%, 45%);
@@ -638,22 +655,22 @@ class CSSmin
638
  return ':first-'. strtolower($matches[1]) .' '. $matches[2];
639
  }
640
 
641
- private function lowercase_directives($matches)
642
  {
643
  return '@'. strtolower($matches[1]);
644
  }
645
 
646
- private function lowercase_pseudo_elements($matches)
647
  {
648
  return ':'. strtolower($matches[1]);
649
  }
650
 
651
- private function lowercase_common_functions($matches)
652
  {
653
  return ':'. strtolower($matches[1]) .'(';
654
  }
655
 
656
- private function lowercase_common_functions_values($matches)
657
  {
658
  return $matches[1] . strtolower($matches[2]);
659
  }
@@ -755,4 +772,4 @@ class CSSmin
755
 
756
  return (int) $size;
757
  }
758
- }
1
  <?php
2
 
3
  /*!
4
+ * cssmin.php 2.4.8-2
5
  * Author: Tubal Martin - http://tubalmartin.me/
6
  * Repo: https://github.com/tubalmartin/YUI-CSS-compressor-PHP-port
7
  *
8
+ * This is a PHP port of the CSS minification tool distributed with YUICompressor,
9
  * itself a port of the cssmin utility by Isaac Schlueter - http://foohack.com/
10
  * Permission is hereby granted to use the PHP version under the same
11
  * conditions as the YUICompressor.
92
  // preserve strings so their content doesn't get accidentally minified
93
  $css = preg_replace_callback('/(?:"(?:[^\\\\"]|\\\\.|\\\\)*")|'."(?:'(?:[^\\\\']|\\\\.|\\\\)*')/S", array($this, 'replace_string'), $css);
94
 
95
+ // Let's divide css code in chunks of 5.000 chars aprox.
96
  // Reason: PHP's PCRE functions like preg_replace have a "backtrack limit"
97
  // of 100.000 chars by default (php < 5.3.7) so if we're dealing with really
98
  // long strings and a (sub)pattern matches a number of chars greater than
101
  $charset = '';
102
  $charset_regexp = '/(@charset)( [^;]+;)/i';
103
  $css_chunks = array();
104
+ $css_chunk_length = 5000; // aprox size, not exact
105
  $start_index = 0;
106
  $i = $css_chunk_length; // save initial iterations
107
  $l = strlen($css);
113
  } else {
114
  // chunk css code securely
115
  while ($i < $l) {
116
+ $i += 50; // save iterations
117
  if ($l - $start_index <= $css_chunk_length || $i >= $l) {
118
  $css_chunks[] = $this->str_slice($css, $start_index);
119
  break;
264
  // Normalize all whitespace strings to single spaces. Easier to work with that way.
265
  $css = preg_replace('/\s+/', ' ', $css);
266
 
267
+ // Fix IE7 issue on matrix filters which browser accept whitespaces between Matrix parameters
268
+ $css = preg_replace_callback('/\s*filter\:\s*progid:DXImageTransform\.Microsoft\.Matrix\(([^\)]+)\)/', array($this, 'preserve_old_IE_specific_matrix_definition'), $css);
269
+
270
  // Shorten & preserve calculations calc(...) since spaces are important
271
  $css = preg_replace_callback('/calc(\(((?:[^\(\)]+|(?1))*)\))/i', array($this, 'replace_calc'), $css);
272
 
292
  // But, be careful not to turn "p :link {...}" into "p:link{...}"
293
  // Swap out any pseudo-class colons with the token, and then swap back.
294
  $css = preg_replace_callback('/(?:^|\})(?:(?:[^\{\:])+\:)+(?:[^\{]*\{)/', array($this, 'replace_colon'), $css);
295
+
296
  // Remove spaces before the things that should not have spaces before them.
297
  $css = preg_replace('/\s+([\!\{\}\;\:\>\+\(\)\]\~\=,])/', '$1', $css);
298
 
320
  // lower case some common function that can be values
321
  // NOTE: rgb() isn't useful as we replace with #hex later, as well as and() is already done for us
322
  $css = preg_replace_callback('/([:,\( ]\s*)(attr|color-stop|from|rgba|to|url|(?:-(?:atsc|khtml|moz|ms|o|wap|webkit)-)?(?:calc|max|min|(?:repeating-)?(?:linear|radial)-gradient)|-webkit-gradient)/iS', array($this, 'lowercase_common_functions_values'), $css);
323
+
324
  // Put the space back in some cases, to support stuff like
325
  // @media screen and (-webkit-min-device-pixel-ratio:0){
326
  $css = preg_replace('/\band\(/i', 'and (', $css);
339
  // Replace 0 length units 0(px,em,%) with 0.
340
  $css = preg_replace('/(^|[^0-9])(?:0?\.)?0(?:em|ex|ch|rem|vw|vh|vm|vmin|cm|mm|in|px|pt|pc|%|deg|g?rad|m?s|k?hz)/iS', '${1}0', $css);
341
 
342
+ // 0% step in a keyframe? restore the % unit
343
+ $css = preg_replace_callback('/(@[a-z\-]*?keyframes[^\{]*?\{)(.*?\}\s*\})/iS', array($this, 'replace_keyframe_zero'), $css);
344
+
345
  // Replace 0 0; or 0 0 0; or 0 0 0 0; with 0.
346
  $css = preg_replace('/\:0(?: 0){1,3}(;|\}| \!)/', ':0$1', $css);
347
 
379
  // Add "/" back to fix Opera -o-device-pixel-ratio query
380
  $css = preg_replace('/'. self::QUERY_FRACTION .'/', '/', $css);
381
 
382
+ // Replace multiple semi-colons in a row by a single one
383
+ // See SF bug #1980989
384
+ $css = preg_replace('/;;+/', ';', $css);
385
+
386
+ // Restore new lines for /*! important comments
387
+ $css = preg_replace('/'. self::NL .'/', "\n", $css);
388
+
389
+ // Lowercase all uppercase properties
390
+ $css = preg_replace_callback('/(\{|\;)([A-Z\-]+)(\:)/', array($this, 'lowercase_properties'), $css);
391
+
392
  // Some source control tools don't like it when files containing lines longer
393
  // than, say 8000 characters, are checked in. The linebreak option is used in
394
  // that case to split long lines after a specific column.
404
  }
405
  }
406
 
407
+ // restore preserved comments and strings in reverse order
408
+ for ($i = count($this->preserved_tokens) - 1; $i >= 0; $i--) {
 
 
 
 
 
 
 
 
 
 
409
  $css = preg_replace('/' . self::TOKEN . $i . '___/', $this->preserved_tokens[$i], $css, 1);
410
  }
411
 
588
  return 'calc('. self::TOKEN . (count($this->preserved_tokens) - 1) . '___' . ')';
589
  }
590
 
591
+ private function preserve_old_IE_specific_matrix_definition($matches)
592
+ {
593
+ $this->preserved_tokens[] = $matches[1];
594
+ return 'filter:progid:DXImageTransform.Microsoft.Matrix(' . self::TOKEN . (count($this->preserved_tokens) - 1) . '___' . ')';
595
+ }
596
+
597
+ private function replace_keyframe_zero($matches)
598
+ {
599
+ return $matches[1] . preg_replace('/0\s*,/', '0%,', preg_replace('/\s*0\s*\{/', '0%{', $matches[2]));
600
+ }
601
+
602
  private function rgb_to_hex($matches)
603
  {
604
  // Support for percentage values rgb(100%, 0%, 45%);
655
  return ':first-'. strtolower($matches[1]) .' '. $matches[2];
656
  }
657
 
658
+ private function lowercase_directives($matches)
659
  {
660
  return '@'. strtolower($matches[1]);
661
  }
662
 
663
+ private function lowercase_pseudo_elements($matches)
664
  {
665
  return ':'. strtolower($matches[1]);
666
  }
667
 
668
+ private function lowercase_common_functions($matches)
669
  {
670
  return ':'. strtolower($matches[1]) .'(';
671
  }
672
 
673
+ private function lowercase_common_functions_values($matches)
674
  {
675
  return $matches[1] . strtolower($matches[2]);
676
  }
772
 
773
  return (int) $size;
774
  }
775
+ }
classes/external/php/yui-php-cssmin-2.4.8-2_fgo.php ADDED
@@ -0,0 +1,777 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /*!
4
+ * cssmin.php 2.4.8-2
5
+ * Author: Tubal Martin - http://tubalmartin.me/
6
+ * Repo: https://github.com/tubalmartin/YUI-CSS-compressor-PHP-port
7
+ *
8
+ * This is a PHP port of the CSS minification tool distributed with YUICompressor,
9
+ * itself a port of the cssmin utility by Isaac Schlueter - http://foohack.com/
10
+ * Permission is hereby granted to use the PHP version under the same
11
+ * conditions as the YUICompressor.
12
+ */
13
+
14
+ /*!
15
+ * YUI Compressor
16
+ * http://developer.yahoo.com/yui/compressor/
17
+ * Author: Julien Lecomte - http://www.julienlecomte.net/
18
+ * Copyright (c) 2013 Yahoo! Inc. All rights reserved.
19
+ * The copyrights embodied in the content of this file are licensed
20
+ * by Yahoo! Inc. under the BSD (revised) open source license.
21
+ */
22
+
23
+ class CSSmin
24
+ {
25
+ const NL = '___YUICSSMIN_PRESERVED_NL___';
26
+ const TOKEN = '___YUICSSMIN_PRESERVED_TOKEN_';
27
+ const COMMENT = '___YUICSSMIN_PRESERVE_CANDIDATE_COMMENT_';
28
+ const CLASSCOLON = '___YUICSSMIN_PSEUDOCLASSCOLON___';
29
+ const QUERY_FRACTION = '___YUICSSMIN_QUERY_FRACTION___';
30
+
31
+ private $comments;
32
+ private $preserved_tokens;
33
+ private $memory_limit;
34
+ private $max_execution_time;
35
+ private $pcre_backtrack_limit;
36
+ private $pcre_recursion_limit;
37
+ private $raise_php_limits;
38
+
39
+ /**
40
+ * @param bool|int $raise_php_limits
41
+ * If true, PHP settings will be raised if needed
42
+ */
43
+ public function __construct($raise_php_limits = TRUE)
44
+ {
45
+ // Set suggested PHP limits
46
+ $this->memory_limit = 128 * 1048576; // 128MB in bytes
47
+ $this->max_execution_time = 60; // 1 min
48
+ $this->pcre_backtrack_limit = 1000 * 1000;
49
+ $this->pcre_recursion_limit = 500 * 1000;
50
+
51
+ $this->raise_php_limits = (bool) $raise_php_limits;
52
+ }
53
+
54
+ /**
55
+ * Minify a string of CSS
56
+ * @param string $css
57
+ * @param int|bool $linebreak_pos
58
+ * @return string
59
+ */
60
+ public function run($css = '', $linebreak_pos = FALSE)
61
+ {
62
+ if (empty($css)) {
63
+ return '';
64
+ }
65
+
66
+ if ($this->raise_php_limits) {
67
+ $this->do_raise_php_limits();
68
+ }
69
+
70
+ $this->comments = array();
71
+ $this->preserved_tokens = array();
72
+
73
+ $start_index = 0;
74
+ $length = strlen($css);
75
+
76
+ $css = $this->extract_data_urls($css);
77
+
78
+ // collect all comment blocks...
79
+ while (($start_index = $this->index_of($css, '/*', $start_index)) >= 0) {
80
+ $end_index = $this->index_of($css, '*/', $start_index + 2);
81
+ if ($end_index < 0) {
82
+ $end_index = $length;
83
+ }
84
+ $comment_found = $this->str_slice($css, $start_index + 2, $end_index);
85
+ $this->comments[] = $comment_found;
86
+ $comment_preserve_string = self::COMMENT . (count($this->comments) - 1) . '___';
87
+ $css = $this->str_slice($css, 0, $start_index + 2) . $comment_preserve_string . $this->str_slice($css, $end_index);
88
+ // Set correct start_index: Fixes issue #2528130
89
+ $start_index = $end_index + 2 + strlen($comment_preserve_string) - strlen($comment_found);
90
+ }
91
+
92
+ // preserve strings so their content doesn't get accidentally minified
93
+ $css = preg_replace_callback('/(?:"(?:[^\\\\"]|\\\\.|\\\\)*")|'."(?:'(?:[^\\\\']|\\\\.|\\\\)*')/S", array($this, 'replace_string'), $css);
94
+
95
+ // Let's divide css code in chunks of 5.000 chars aprox.
96
+ // Reason: PHP's PCRE functions like preg_replace have a "backtrack limit"
97
+ // of 100.000 chars by default (php < 5.3.7) so if we're dealing with really
98
+ // long strings and a (sub)pattern matches a number of chars greater than
99
+ // the backtrack limit number (i.e. /(.*)/s) PCRE functions may fail silently
100
+ // returning NULL and $css would be empty.
101
+ $charset = '';
102
+ $charset_regexp = '/(@charset)( [^;]+;)/i';
103
+ $css_chunks = array();
104
+ $css_chunk_length = 5000; // aprox size, not exact
105
+ $start_index = 0;
106
+ $i = $css_chunk_length; // save initial iterations
107
+ $l = strlen($css);
108
+
109
+
110
+ // if the number of characters is 25000 or less, do not chunk
111
+ if ($l <= $css_chunk_length) {
112
+ $css_chunks[] = $css;
113
+ } else {
114
+ // chunk css code securely
115
+ while ($i < $l) {
116
+ $i += 50; // save iterations
117
+ if ($l - $start_index <= $css_chunk_length || $i >= $l) {
118
+ $css_chunks[] = $this->str_slice($css, $start_index);
119
+ break;
120
+ }
121
+ if ($css[$i - 1] === '}' && $i - $start_index > $css_chunk_length) {
122
+ // If there are two ending curly braces }} separated or not by spaces,
123
+ // join them in the same chunk (i.e. @media blocks)
124
+ $next_chunk = substr($css, $i);
125
+ if (preg_match('/^\s*\}/', $next_chunk)) {
126
+ $i = $i + $this->index_of($next_chunk, '}') + 1;
127
+ }
128
+
129
+ $css_chunks[] = $this->str_slice($css, $start_index, $i);
130
+ $start_index = $i;
131
+ }
132
+ }
133
+ }
134
+
135
+ // Minify each chunk
136
+ for ($i = 0, $n = count($css_chunks); $i < $n; $i++) {
137
+ $css_chunks[$i] = $this->minify($css_chunks[$i], $linebreak_pos);
138
+ // Keep the first @charset at-rule found
139
+ if (empty($charset) && preg_match($charset_regexp, $css_chunks[$i], $matches)) {
140
+ $charset = strtolower($matches[1]) . $matches[2];
141
+ }
142
+ // Delete all @charset at-rules
143
+ $css_chunks[$i] = preg_replace($charset_regexp, '', $css_chunks[$i]);
144
+ }
145
+
146
+ // Update the first chunk and push the charset to the top of the file.
147
+ $css_chunks[0] = $charset . $css_chunks[0];
148
+
149
+ return implode('', $css_chunks);
150
+ }
151
+
152
+ /**
153
+ * Sets the memory limit for this script
154
+ * @param int|string $limit
155
+ */
156
+ public function set_memory_limit($limit)
157
+ {
158
+ $this->memory_limit = $this->normalize_int($limit);
159
+ }
160
+
161
+ /**
162
+ * Sets the maximum execution time for this script
163
+ * @param int|string $seconds
164
+ */
165
+ public function set_max_execution_time($seconds)
166
+ {
167
+ $this->max_execution_time = (int) $seconds;
168
+ }
169
+
170
+ /**
171
+ * Sets the PCRE backtrack limit for this script
172
+ * @param int $limit
173
+ */
174
+ public function set_pcre_backtrack_limit($limit)
175
+ {
176
+ $this->pcre_backtrack_limit = (int) $limit;
177
+ }
178
+
179
+ /**
180
+ * Sets the PCRE recursion limit for this script
181
+ * @param int $limit
182
+ */
183
+ public function set_pcre_recursion_limit($limit)
184
+ {
185
+ $this->pcre_recursion_limit = (int) $limit;
186
+ }
187
+
188
+ /**
189
+ * Try to configure PHP to use at least the suggested minimum settings
190
+ */
191
+ private function do_raise_php_limits()
192
+ {
193
+ $php_limits = array(
194
+ 'memory_limit' => $this->memory_limit,
195
+ 'max_execution_time' => $this->max_execution_time,
196
+ 'pcre.backtrack_limit' => $this->pcre_backtrack_limit,
197
+ 'pcre.recursion_limit' => $this->pcre_recursion_limit
198
+ );
199
+
200
+ // If current settings are higher respect them.
201
+ foreach ($php_limits as $name => $suggested) {
202
+ $current = $this->normalize_int(ini_get($name));
203
+ // memory_limit exception: allow -1 for "no memory limit".
204
+ if ($current > -1 && ($suggested == -1 || $current < $suggested)) {
205
+ ini_set($name, $suggested);
206
+ }
207
+ }
208
+ }
209
+
210
+ /**
211
+ * Does bulk of the minification
212
+ * @param string $css
213
+ * @param int|bool $linebreak_pos
214
+ * @return string
215
+ */
216
+ private function minify($css, $linebreak_pos)
217
+ {
218
+ // strings are safe, now wrestle the comments
219
+ for ($i = 0, $max = count($this->comments); $i < $max; $i++) {
220
+
221
+ $token = $this->comments[$i];
222
+ $placeholder = '/' . self::COMMENT . $i . '___/';
223
+
224
+ // ! in the first position of the comment means preserve
225
+ // so push to the preserved tokens keeping the !
226
+ if (substr($token, 0, 1) === '!') {
227
+ $this->preserved_tokens[] = $token;
228
+ $token_tring = self::TOKEN . (count($this->preserved_tokens) - 1) . '___';
229
+ $css = preg_replace($placeholder, $token_tring, $css, 1);
230
+ // Preserve new lines for /*! important comments
231
+ $css = preg_replace('/\s*[\n\r\f]+\s*(\/\*'. $token_tring .')/S', self::NL.'$1', $css);
232
+ $css = preg_replace('/('. $token_tring .'\*\/)\s*[\n\r\f]+\s*/', '$1'.self::NL, $css);
233
+ continue;
234
+ }
235
+
236
+ // \ in the last position looks like hack for Mac/IE5
237
+ // shorten that to /*\*/ and the next one to /**/
238
+ if (substr($token, (strlen($token) - 1), 1) === '\\') {
239
+ $this->preserved_tokens[] = '\\';
240
+ $css = preg_replace($placeholder, self::TOKEN . (count($this->preserved_tokens) - 1) . '___', $css, 1);
241
+ $i = $i + 1; // attn: advancing the loop
242
+ $this->preserved_tokens[] = '';
243
+ $css = preg_replace('/' . self::COMMENT . $i . '___/', self::TOKEN . (count($this->preserved_tokens) - 1) . '___', $css, 1);
244
+ continue;
245
+ }
246
+
247
+ // keep empty comments after child selectors (IE7 hack)
248
+ // e.g. html >/**/ body
249
+ if (strlen($token) === 0) {
250
+ $start_index = $this->index_of($css, $this->str_slice($placeholder, 1, -1));
251
+ if ($start_index > 2) {
252
+ if (substr($css, $start_index - 3, 1) === '>') {
253
+ $this->preserved_tokens[] = '';
254
+ $css = preg_replace($placeholder, self::TOKEN . (count($this->preserved_tokens) - 1) . '___', $css, 1);
255
+ }
256
+ }
257
+ }
258
+
259
+ // in all other cases kill the comment
260
+ $css = preg_replace('/\/\*' . $this->str_slice($placeholder, 1, -1) . '\*\//', '', $css, 1);
261
+ }
262
+
263
+
264
+ // Normalize all whitespace strings to single spaces. Easier to work with that way.
265
+ $css = preg_replace('/\s+/', ' ', $css);
266
+
267
+ // Fix IE7 issue on matrix filters which browser accept whitespaces between Matrix parameters
268
+ $css = preg_replace_callback('/\s*filter\:\s*progid:DXImageTransform\.Microsoft\.Matrix\(([^\)]+)\)/', array($this, 'preserve_old_IE_specific_matrix_definition'), $css);
269
+
270
+ // Shorten & preserve calculations calc(...) since spaces are important
271
+ $css = preg_replace_callback('/calc(\(((?:[^\(\)]+|(?1))*)\))/i', array($this, 'replace_calc'), $css);
272
+
273
+ // Replace positive sign from numbers preceded by : or a white-space before the leading space is removed
274
+ // +1.2em to 1.2em, +.8px to .8px, +2% to 2%
275
+ $css = preg_replace('/((?<!\\\\)\:|\s)\+(\.?\d+)/S', '$1$2', $css);
276
+
277
+ // Remove leading zeros from integer and float numbers preceded by : or a white-space
278
+ // 000.6 to .6, -0.8 to -.8, 0050 to 50, -01.05 to -1.05
279
+ $css = preg_replace('/((?<!\\\\)\:|\s)(\-?)0+(\.?\d+)/S', '$1$2$3', $css);
280
+
281
+ // Remove trailing zeros from float numbers preceded by : or a white-space
282
+ // -6.0100em to -6.01em, .0100 to .01, 1.200px to 1.2px
283
+ $css = preg_replace('/((?<!\\\\)\:|\s)(\-?)(\d?\.\d+?)0+([^\d])/S', '$1$2$3$4', $css);
284
+
285
+ // Remove trailing .0 -> -9.0 to -9
286
+ $css = preg_replace('/((?<!\\\\)\:|\s)(\-?\d+)\.0([^\d])/S', '$1$2$3', $css);
287
+
288
+ // Replace 0 length numbers with 0
289
+ $css = preg_replace('/((?<!\\\\)\:|\s)\-?\.?0+([^\d])/S', '${1}0$2', $css);
290
+
291
+ // Remove the spaces before the things that should not have spaces before them.
292
+ // But, be careful not to turn "p :link {...}" into "p:link{...}"
293
+ // Swap out any pseudo-class colons with the token, and then swap back.
294
+ // fgo; simpler regex to avoid stack overflow in PCRE, cfr. https://github.com/tubalmartin/YUI-CSS-compressor-PHP-port/issues/11
295
+ // $css = preg_replace_callback('/(?:^|\})(?:(?:[^\{\:])+\:)+(?:[^\{]*\{)/', array($this, 'replace_colon'), $css);
296
+ $css = preg_replace_callback('/(?:(?:^|\})([^\{]*\s:))/', array($this, 'replace_colon'), $css);
297
+
298
+ // Remove spaces before the things that should not have spaces before them.
299
+ $css = preg_replace('/\s+([\!\{\}\;\:\>\+\(\)\]\~\=,])/', '$1', $css);
300
+
301
+ // Restore spaces for !important
302
+ $css = preg_replace('/\!important/i', ' !important', $css);
303
+
304
+ // bring back the colon
305
+ $css = preg_replace('/' . self::CLASSCOLON . '/', ':', $css);
306
+
307
+ // retain space for special IE6 cases
308
+ $css = preg_replace_callback('/\:first\-(line|letter)(\{|,)/i', array($this, 'lowercase_pseudo_first'), $css);
309
+
310
+ // no space after the end of a preserved comment
311
+ $css = preg_replace('/\*\/ /', '*/', $css);
312
+
313
+ // lowercase some popular @directives
314
+ $css = preg_replace_callback('/@(font-face|import|(?:-(?:atsc|khtml|moz|ms|o|wap|webkit)-)?keyframe|media|page|namespace)/i', array($this, 'lowercase_directives'), $css);
315
+
316
+ // lowercase some more common pseudo-elements
317
+ $css = preg_replace_callback('/:(active|after|before|checked|disabled|empty|enabled|first-(?:child|of-type)|focus|hover|last-(?:child|of-type)|link|only-(?:child|of-type)|root|:selection|target|visited)/i', array($this, 'lowercase_pseudo_elements'), $css);
318
+
319
+ // lowercase some more common functions
320
+ $css = preg_replace_callback('/:(lang|not|nth-child|nth-last-child|nth-last-of-type|nth-of-type|(?:-(?:moz|webkit)-)?any)\(/i', array($this, 'lowercase_common_functions'), $css);
321
+
322
+ // lower case some common function that can be values
323
+ // NOTE: rgb() isn't useful as we replace with #hex later, as well as and() is already done for us
324
+ $css = preg_replace_callback('/([:,\( ]\s*)(attr|color-stop|from|rgba|to|url|(?:-(?:atsc|khtml|moz|ms|o|wap|webkit)-)?(?:calc|max|min|(?:repeating-)?(?:linear|radial)-gradient)|-webkit-gradient)/iS', array($this, 'lowercase_common_functions_values'), $css);
325
+
326
+ // Put the space back in some cases, to support stuff like
327
+ // @media screen and (-webkit-min-device-pixel-ratio:0){
328
+ $css = preg_replace('/\band\(/i', 'and (', $css);
329
+
330
+ // Remove the spaces after the things that should not have spaces after them.
331
+ $css = preg_replace('/([\!\{\}\:;\>\+\(\[\~\=,])\s+/S', '$1', $css);
332
+
333
+ // remove unnecessary semicolons
334
+ $css = preg_replace('/;+\}/', '}', $css);
335
+
336
+ // Fix for issue: #2528146
337
+ // Restore semicolon if the last property is prefixed with a `*` (lte IE7 hack)
338
+ // to avoid issues on Symbian S60 3.x browsers.
339
+ $css = preg_replace('/(\*[a-z0-9\-]+\s*\:[^;\}]+)(\})/', '$1;$2', $css);
340
+
341
+ // Replace 0 length units 0(px,em,%) with 0.
342
+ $css = preg_replace('/(^|[^0-9])(?:0?\.)?0(?:em|ex|ch|rem|vw|vh|vm|vmin|cm|mm|in|px|pt|pc|%|deg|g?rad|m?s|k?hz)/iS', '${1}0', $css);
343
+
344
+ // 0% step in a keyframe? restore the % unit
345
+ $css = preg_replace_callback('/(@[a-z\-]*?keyframes[^\{]*?\{)(.*?\}\s*\})/iS', array($this, 'replace_keyframe_zero'), $css);
346
+
347
+ // Replace 0 0; or 0 0 0; or 0 0 0 0; with 0.
348
+ $css = preg_replace('/\:0(?: 0){1,3}(;|\}| \!)/', ':0$1', $css);
349
+
350
+ // Fix for issue: #2528142
351
+ // Replace text-shadow:0; with text-shadow:0 0 0;
352
+ $css = preg_replace('/(text-shadow\:0)(;|\}| \!)/i', '$1 0 0$2', $css);
353
+
354
+ // Replace background-position:0; with background-position:0 0;
355
+ // same for transform-origin
356
+ // Changing -webkit-mask-position: 0 0 to just a single 0 will result in the second parameter defaulting to 50% (center)
357
+ $css = preg_replace('/(background\-position|webkit-mask-position|(?:webkit|moz|o|ms|)\-?transform\-origin)\:0(;|\}| \!)/iS', '$1:0 0$2', $css);
358
+
359
+ // Shorten colors from rgb(51,102,153) to #336699, rgb(100%,0%,0%) to #ff0000 (sRGB color space)
360
+ // Shorten colors from hsl(0, 100%, 50%) to #ff0000 (sRGB color space)
361
+ // This makes it more likely that it'll get further compressed in the next step.
362
+ $css = preg_replace_callback('/rgb\s*\(\s*([0-9,\s\-\.\%]+)\s*\)(.{1})/i', array($this, 'rgb_to_hex'), $css);
363
+ $css = preg_replace_callback('/hsl\s*\(\s*([0-9,\s\-\.\%]+)\s*\)(.{1})/i', array($this, 'hsl_to_hex'), $css);
364
+
365
+ // Shorten colors from #AABBCC to #ABC or short color name.
366
+ $css = $this->compress_hex_colors($css);
367
+
368
+ // border: none to border:0, outline: none to outline:0
369
+ $css = preg_replace('/(border\-?(?:top|right|bottom|left|)|outline)\:none(;|\}| \!)/iS', '$1:0$2', $css);
370
+
371
+ // shorter opacity IE filter
372
+ $css = preg_replace('/progid\:DXImageTransform\.Microsoft\.Alpha\(Opacity\=/i', 'alpha(opacity=', $css);
373
+
374
+ // Find a fraction that is used for Opera's -o-device-pixel-ratio query
375
+ // Add token to add the "\" back in later
376
+ $css = preg_replace('/\(([a-z\-]+):([0-9]+)\/([0-9]+)\)/i', '($1:$2'. self::QUERY_FRACTION .'$3)', $css);
377
+
378
+ // Remove empty rules.
379
+ $css = preg_replace('/[^\};\{\/]+\{\}/S', '', $css);
380
+
381
+ // Add "/" back to fix Opera -o-device-pixel-ratio query
382
+ $css = preg_replace('/'. self::QUERY_FRACTION .'/', '/', $css);
383
+
384
+ // Replace multiple semi-colons in a row by a single one
385
+ // See SF bug #1980989
386
+ $css = preg_replace('/;;+/', ';', $css);
387
+
388
+ // Restore new lines for /*! important comments
389
+ $css = preg_replace('/'. self::NL .'/', "\n", $css);
390
+
391
+ // Lowercase all uppercase properties
392
+ $css = preg_replace_callback('/(\{|\;)([A-Z\-]+)(\:)/', array($this, 'lowercase_properties'), $css);
393
+
394
+ // Some source control tools don't like it when files containing lines longer
395
+ // than, say 8000 characters, are checked in. The linebreak option is used in
396
+ // that case to split long lines after a specific column.
397
+ if ($linebreak_pos !== FALSE && (int) $linebreak_pos >= 0) {
398
+ $linebreak_pos = (int) $linebreak_pos;
399
+ $start_index = $i = 0;
400
+ while ($i < strlen($css)) {
401
+ $i++;
402
+ if ($css[$i - 1] === '}' && $i - $start_index > $linebreak_pos) {
403
+ $css = $this->str_slice($css, 0, $i) . "\n" . $this->str_slice($css, $i);
404
+ $start_index = $i;
405
+ }
406
+ }
407
+ }
408
+
409
+ // restore preserved comments and strings in reverse order
410
+ for ($i = count($this->preserved_tokens) - 1; $i >= 0; $i--) {
411
+ $css = preg_replace('/' . self::TOKEN . $i . '___/', $this->preserved_tokens[$i], $css, 1);
412
+ }
413
+
414
+ // Trim the final string (for any leading or trailing white spaces)
415
+ return trim($css);
416
+ }
417
+
418
+ /**
419
+ * Utility method to replace all data urls with tokens before we start
420
+ * compressing, to avoid performance issues running some of the subsequent
421
+ * regexes against large strings chunks.
422
+ *
423
+ * @param string $css
424
+ * @return string
425
+ */
426
+ private function extract_data_urls($css)
427
+ {
428
+ // Leave data urls alone to increase parse performance.
429
+ $max_index = strlen($css) - 1;
430
+ $append_index = $index = $last_index = $offset = 0;
431
+ $sb = array();
432
+ $pattern = '/url\(\s*(["\']?)data\:/i';
433
+
434
+ // Since we need to account for non-base64 data urls, we need to handle
435
+ // ' and ) being part of the data string. Hence switching to indexOf,
436
+ // to determine whether or not we have matching string terminators and
437
+ // handling sb appends directly, instead of using matcher.append* methods.
438
+
439
+ while (preg_match($pattern, $css, $m, 0, $offset)) {
440
+ $index = $this->index_of($css, $m[0], $offset);
441
+ $last_index = $index + strlen($m[0]);
442
+ $start_index = $index + 4; // "url(".length()
443
+ $end_index = $last_index - 1;
444
+ $terminator = $m[1]; // ', " or empty (not quoted)
445
+ $found_terminator = FALSE;
446
+
447
+ if (strlen($terminator) === 0) {
448
+ $terminator = ')';
449
+ }
450
+
451
+ while ($found_terminator === FALSE && $end_index+1 <= $max_index) {
452
+ $end_index = $this->index_of($css, $terminator, $end_index + 1);
453
+
454
+ // endIndex == 0 doesn't really apply here
455
+ if ($end_index > 0 && substr($css, $end_index - 1, 1) !== '\\') {
456
+ $found_terminator = TRUE;
457
+ if (')' != $terminator) {
458
+ $end_index = $this->index_of($css, ')', $end_index);
459
+ }
460
+ }
461
+ }
462
+
463
+ // Enough searching, start moving stuff over to the buffer
464
+ $sb[] = $this->str_slice($css, $append_index, $index);
465
+
466
+ if ($found_terminator) {
467
+ $token = $this->str_slice($css, $start_index, $end_index);
468
+ $token = preg_replace('/\s+/', '', $token);
469
+ $this->preserved_tokens[] = $token;
470
+
471
+ $preserver = 'url(' . self::TOKEN . (count($this->preserved_tokens) - 1) . '___)';
472
+ $sb[] = $preserver;
473
+
474
+ $append_index = $end_index + 1;
475
+ } else {
476
+ // No end terminator found, re-add the whole match. Should we throw/warn here?
477
+ $sb[] = $this->str_slice($css, $index, $last_index);
478
+ $append_index = $last_index;
479
+ }
480
+
481
+ $offset = $last_index;
482
+ }
483
+
484
+ $sb[] = $this->str_slice($css, $append_index);
485
+
486
+ return implode('', $sb);
487
+ }
488
+
489
+ /**
490
+ * Utility method to compress hex color values of the form #AABBCC to #ABC or short color name.
491
+ *
492
+ * DOES NOT compress CSS ID selectors which match the above pattern (which would break things).
493
+ * e.g. #AddressForm { ... }
494
+ *
495
+ * DOES NOT compress IE filters, which have hex color values (which would break things).
496
+ * e.g. filter: chroma(color="#FFFFFF");
497
+ *
498
+ * DOES NOT compress invalid hex values.
499
+ * e.g. background-color: #aabbccdd
500
+ *
501
+ * @param string $css
502
+ * @return string
503
+ */
504
+ private function compress_hex_colors($css)
505
+ {
506
+ // Look for hex colors inside { ... } (to avoid IDs) and which don't have a =, or a " in front of them (to avoid filters)
507
+ $pattern = '/(\=\s*?["\']?)?#([0-9a-f])([0-9a-f])([0-9a-f])([0-9a-f])([0-9a-f])([0-9a-f])(\}|[^0-9a-f{][^{]*?\})/iS';
508
+ $_index = $index = $last_index = $offset = 0;
509
+ $sb = array();
510
+ // See: http://ajaxmin.codeplex.com/wikipage?title=CSS%20Colors
511
+ $short_safe = array(
512
+ '#808080' => 'gray',
513
+ '#008000' => 'green',
514
+ '#800000' => 'maroon',
515
+ '#000080' => 'navy',
516
+ '#808000' => 'olive',
517
+ '#ffa500' => 'orange',
518
+ '#800080' => 'purple',
519
+ '#c0c0c0' => 'silver',
520
+ '#008080' => 'teal',
521
+ '#f00' => 'red'
522
+ );
523
+
524
+ while (preg_match($pattern, $css, $m, 0, $offset)) {
525
+ $index = $this->index_of($css, $m[0], $offset);
526
+ $last_index = $index + strlen($m[0]);
527
+ $is_filter = $m[1] !== null && $m[1] !== '';
528
+
529
+ $sb[] = $this->str_slice($css, $_index, $index);
530
+
531
+ if ($is_filter) {
532
+ // Restore, maintain case, otherwise filter will break
533
+ $sb[] = $m[1] . '#' . $m[2] . $m[3] . $m[4] . $m[5] . $m[6] . $m[7];
534
+ } else {
535
+ if (strtolower($m[2]) == strtolower($m[3]) &&
536
+ strtolower($m[4]) == strtolower($m[5]) &&
537
+ strtolower($m[6]) == strtolower($m[7])) {
538
+ // Compress.
539
+ $hex = '#' . strtolower($m[3] . $m[5] . $m[7]);
540
+ } else {
541
+ // Non compressible color, restore but lower case.
542
+ $hex = '#' . strtolower($m[2] . $m[3] . $m[4] . $m[5] . $m[6] . $m[7]);
543
+ }
544
+ // replace Hex colors to short safe color names
545
+ $sb[] = array_key_exists($hex, $short_safe) ? $short_safe[$hex] : $hex;
546
+ }
547
+
548
+ $_index = $offset = $last_index - strlen($m[8]);
549
+ }
550
+
551
+ $sb[] = $this->str_slice($css, $_index);
552
+
553
+ return implode('', $sb);
554
+ }
555
+
556
+ /* CALLBACKS
557
+ * ---------------------------------------------------------------------------------------------
558
+ */
559
+
560
+ private function replace_string($matches)
561
+ {
562
+ $match = $matches[0];
563
+ $quote = substr($match, 0, 1);
564
+ // Must use addcslashes in PHP to avoid parsing of backslashes
565
+ $match = addcslashes($this->str_slice($match, 1, -1), '\\');
566
+
567
+ // maybe the string contains a comment-like substring?
568
+ // one, maybe more? put'em back then
569
+ if (($pos = $this->index_of($match, self::COMMENT)) >= 0) {
570
+ for ($i = 0, $max = count($this->comments); $i < $max; $i++) {
571
+ $match = preg_replace('/' . self::COMMENT . $i . '___/', $this->comments[$i], $match, 1);
572
+ }
573
+ }
574
+
575
+ // minify alpha opacity in filter strings
576
+ $match = preg_replace('/progid\:DXImageTransform\.Microsoft\.Alpha\(Opacity\=/i', 'alpha(opacity=', $match);
577
+
578
+ $this->preserved_tokens[] = $match;
579
+ return $quote . self::TOKEN . (count($this->preserved_tokens) - 1) . '___' . $quote;
580
+ }
581
+
582
+ private function replace_colon($matches)
583
+ {
584
+ return preg_replace('/\:/', self::CLASSCOLON, $matches[0]);
585
+ }
586
+
587
+ private function replace_calc($matches)
588
+ {
589
+ $this->preserved_tokens[] = trim(preg_replace('/\s*([\*\/\(\),])\s*/', '$1', $matches[2]));
590
+ return 'calc('. self::TOKEN . (count($this->preserved_tokens) - 1) . '___' . ')';
591
+ }
592
+
593
+ private function preserve_old_IE_specific_matrix_definition($matches)
594
+ {
595
+ $this->preserved_tokens[] = $matches[1];
596
+ return 'filter:progid:DXImageTransform.Microsoft.Matrix(' . self::TOKEN . (count($this->preserved_tokens) - 1) . '___' . ')';
597
+ }
598
+
599
+ private function replace_keyframe_zero($matches)
600
+ {
601
+ return $matches[1] . preg_replace('/0\s*,/', '0%,', preg_replace('/\s*0\s*\{/', '0%{', $matches[2]));
602
+ }
603
+
604
+ private function rgb_to_hex($matches)
605
+ {
606
+ // Support for percentage values rgb(100%, 0%, 45%);
607
+ if ($this->index_of($matches[1], '%') >= 0){
608
+ $rgbcolors = explode(',', str_replace('%', '', $matches[1]));
609
+ for ($i = 0; $i < count($rgbcolors); $i++) {
610
+ $rgbcolors[$i] = $this->round_number(floatval($rgbcolors[$i]) * 2.55);
611
+ }
612
+ } else {
613
+ $rgbcolors = explode(',', $matches[1]);
614
+ }
615
+
616
+ // Values outside the sRGB color space should be clipped (0-255)
617
+ for ($i = 0; $i < count($rgbcolors); $i++) {
618
+ $rgbcolors[$i] = $this->clamp_number(intval($rgbcolors[$i], 10), 0, 255);
619
+ $rgbcolors[$i] = sprintf("%02x", $rgbcolors[$i]);
620
+ }
621
+
622
+ // Fix for issue #2528093
623
+ if (!preg_match('/[\s\,\);\}]/', $matches[2])){
624
+ $matches[2] = ' ' . $matches[2];
625
+ }
626
+
627
+ return '#' . implode('', $rgbcolors) . $matches[2];
628
+ }
629
+
630
+ private function hsl_to_hex($matches)
631
+ {
632
+ $values = explode(',', str_replace('%', '', $matches[1]));
633
+ $h = floatval($values[0]);
634
+ $s = floatval($values[1]);
635
+ $l = floatval($values[2]);
636
+
637
+ // Wrap and clamp, then fraction!
638
+ $h = ((($h % 360) + 360) % 360) / 360;
639
+ $s = $this->clamp_number($s, 0, 100) / 100;
640
+ $l = $this->clamp_number($l, 0, 100) / 100;
641
+
642
+ if ($s == 0) {
643
+ $r = $g = $b = $this->round_number(255 * $l);
644
+ } else {
645
+ $v2 = $l < 0.5 ? $l * (1 + $s) : ($l + $s) - ($s * $l);
646
+ $v1 = (2 * $l) - $v2;
647
+ $r = $this->round_number(255 * $this->hue_to_rgb($v1, $v2, $h + (1/3)));
648
+ $g = $this->round_number(255 * $this->hue_to_rgb($v1, $v2, $h));
649
+ $b = $this->round_number(255 * $this->hue_to_rgb($v1, $v2, $h - (1/3)));
650
+ }
651
+
652
+ return $this->rgb_to_hex(array('', $r.','.$g.','.$b, $matches[2]));
653
+ }
654
+
655
+ private function lowercase_pseudo_first($matches)
656
+ {
657
+ return ':first-'. strtolower($matches[1]) .' '. $matches[2];
658
+ }
659
+
660
+ private function lowercase_directives($matches)
661
+ {
662
+ return '@'. strtolower($matches[1]);
663
+ }
664
+
665
+ private function lowercase_pseudo_elements($matches)
666
+ {
667
+ return ':'. strtolower($matches[1]);
668
+ }
669
+
670
+ private function lowercase_common_functions($matches)
671
+ {
672
+ return ':'. strtolower($matches[1]) .'(';
673
+ }
674
+
675
+ private function lowercase_common_functions_values($matches)
676
+ {
677
+ return $matches[1] . strtolower($matches[2]);
678
+ }
679
+
680
+ private function lowercase_properties($matches)
681
+ {
682
+ return $matches[1].strtolower($matches[2]).$matches[3];
683
+ }
684
+
685
+ /* HELPERS
686
+ * ---------------------------------------------------------------------------------------------
687
+ */
688
+
689
+ private function hue_to_rgb($v1, $v2, $vh)
690
+ {
691
+ $vh = $vh < 0 ? $vh + 1 : ($vh > 1 ? $vh - 1 : $vh);
692
+ if ($vh * 6 < 1) return $v1 + ($v2 - $v1) * 6 * $vh;
693
+ if ($vh * 2 < 1) return $v2;
694
+ if ($vh * 3 < 2) return $v1 + ($v2 - $v1) * ((2/3) - $vh) * 6;
695
+ return $v1;
696
+ }
697
+
698
+ private function round_number($n)
699
+ {
700
+ return intval(floor(floatval($n) + 0.5), 10);
701
+ }
702
+
703
+ private function clamp_number($n, $min, $max)
704
+ {
705
+ return min(max($n, $min), $max);
706
+ }
707
+
708
+ /**
709
+ * PHP port of Javascript's "indexOf" function for strings only
710
+ * Author: Tubal Martin http://blog.margenn.com
711
+ *
712
+ * @param string $haystack
713
+ * @param string $needle
714
+ * @param int $offset index (optional)
715
+ * @return int
716
+ */
717
+ private function index_of($haystack, $needle, $offset = 0)
718
+ {
719
+ $index = strpos($haystack, $needle, $offset);
720
+
721
+ return ($index !== FALSE) ? $index : -1;
722
+ }
723
+
724
+ /**
725
+ * PHP port of Javascript's "slice" function for strings only
726
+ * Author: Tubal Martin http://blog.margenn.com
727
+ * Tests: http://margenn.com/tubal/str_slice/
728
+ *
729
+ * @param string $str
730
+ * @param int $start index
731
+ * @param int|bool $end index (optional)
732
+ * @return string
733
+ */
734
+ private function str_slice($str, $start = 0, $end = FALSE)
735
+ {
736
+ if ($end !== FALSE && ($start < 0 || $end <= 0)) {
737
+ $max = strlen($str);
738
+
739
+ if ($start < 0) {
740
+ if (($start = $max + $start) < 0) {
741
+ return '';
742
+ }
743
+ }
744
+
745
+ if ($end < 0) {
746
+ if (($end = $max + $end) < 0) {
747
+ return '';
748
+ }
749
+ }
750
+
751
+ if ($end <= $start) {
752
+ return '';
753
+ }
754
+ }
755
+
756
+ $slice = ($end === FALSE) ? substr($str, $start) : substr($str, $start, $end - $start);
757
+ return ($slice === FALSE) ? '' : $slice;
758
+ }
759
+
760
+ /**
761
+ * Convert strings like "64M" or "30" to int values
762
+ * @param mixed $size
763
+ * @return int
764
+ */
765
+ private function normalize_int($size)
766
+ {
767
+ if (is_string($size)) {
768
+ switch (substr($size, -1)) {
769
+ case 'M': case 'm': return $size * 1048576;
770
+ case 'K': case 'k': return $size * 1024;
771
+ case 'G': case 'g': return $size * 1073741824;
772
+ }
773
+ }
774
+
775
+ return (int) $size;
776
+ }
777
+ }
localization/autoptimize-de_DE.mo CHANGED
Binary file
localization/autoptimize-de_DE.po CHANGED
@@ -1,19 +1,19 @@
1
- # Copyright (C) 2013 Autoptimize
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Autoptimize 1.7.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
- "POT-Creation-Date: 2013-10-21 07:38:13+00:00\n"
8
- "PO-Revision-Date: 2013-10-21 08:02-0800\n"
9
- "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
10
- "Language-Team: LANGUAGE <LL@li.org>\n"
11
  "MIME-Version: 1.0\n"
12
  "Content-Type: text/plain; charset=UTF-8\n"
13
  "Content-Transfer-Encoding: 8bit\n"
 
 
 
14
  "X-Generator: Poedit 1.5.7\n"
15
 
16
- #: autoptimize.php:66
17
  msgid ""
18
  "Thank you for installing and activating Autoptimize. Please configure it "
19
  "under \"Settings\" -> \"Autoptimize\" to start improving your site's "
@@ -23,7 +23,7 @@ msgstr ""
23
  "konfiguriere das Plugin unter \"Einstellungen\" -> \"Autoptimize\" um die "
24
  "Performance deiner Webseite zu verbessern."
25
 
26
- #: autoptimize.php:72
27
  msgid ""
28
  "Autoptimize has just been updated. Please <strong>test your site now</"
29
  "strong> and adapt Autoptimize config if needed."
@@ -37,11 +37,11 @@ msgstr "Autoptimize Einstellungen"
37
 
38
  #: classes/autoptimizeConfig.php:62 classes/autoptimizeConfig.php:68
39
  msgid "Show advanced settings"
40
- msgstr "Erweiterte Einstellungen anzeigen"
41
 
42
  #: classes/autoptimizeConfig.php:63 classes/autoptimizeConfig.php:69
43
  msgid "Hide advanced settings"
44
- msgstr "Erweiterte Einstellungen verstecken"
45
 
46
  #: classes/autoptimizeConfig.php:77
47
  msgid "HTML Options"
@@ -60,7 +60,7 @@ msgid ""
60
  "Enable this if you want HTML comments to remain in the page, needed for e.g. "
61
  "AdSense to function properly."
62
  msgstr ""
63
- "Aktiviere diese Option wenn HTML Kommentare erhalten bleiben sollen, "
64
  "beispielsweise um AdSense einwandfrei zu kennzeichnen."
65
 
66
  #: classes/autoptimizeConfig.php:90
@@ -82,8 +82,8 @@ msgid ""
82
  "themes."
83
  msgstr ""
84
  "Aus Performance-Gründen ist es besser, JavaScript am Ende des HTML-Codes "
85
- "einzufügen. Dies kann in manchen Fällen allerdings zu Problemen führen, wenn "
86
- "beispielsweise Themes auf jQuery basieren."
87
 
88
  #: classes/autoptimizeConfig.php:102
89
  msgid "Look for scripts only in &lt;head&gt;?"
@@ -94,24 +94,23 @@ msgid ""
94
  "Mostly usefull in combination with previous option when using jQuery-based "
95
  "templates, but might help keeping cache size under control."
96
  msgstr ""
97
- "Meistens nützlich in Kombination mit den vorhergehenden Optionen, wenn "
98
- "beispielsweise jQuery basierte Themes benutzt werden. Kann auch helfen die "
99
- "Größe des Caches unter Kontrolle zu halten."
100
 
101
  #: classes/autoptimizeConfig.php:107
102
- msgid "Exclude scripts from autoptimize:"
103
  msgstr "Folgende Skripte von Autoptimize ausschließen:"
104
 
105
  #: classes/autoptimizeConfig.php:109
106
  msgid ""
107
- "A comma-seperated list of scripts you want to exclude from being "
108
- "Autoptimized, for example 'whatever.js, another.js' (without the quotes) to "
109
- "exclude those scripts from being aggregated and minimized by Autoptimize."
110
  msgstr ""
111
- "Eine mit Kommas getrennte Liste von Skripten die von Autoptimized "
112
- "augeschlossen werden sollen. Zum Beispiel kann folgende Liste verwendet "
113
- "werden 'whatever.js, another.js' (ohne Anführungszeichen) um die genannten "
114
- "Skripte von der Optimierung durch Autoptimize auszuschließen."
115
 
116
  #: classes/autoptimizeConfig.php:112
117
  msgid "Add try-catch wrapping?"
@@ -141,126 +140,148 @@ msgid ""
141
  "Enable this to include small background-images in the CSS itself instead of "
142
  "as seperate downloads."
143
  msgstr ""
144
- "Aktiviere diese Option um kleine Hintergrundbilder in CSS einzufügen anstatt "
145
- "diese separat herunterzuladen."
146
 
147
  #: classes/autoptimizeConfig.php:130
148
- msgid "Defer CSS loading?"
149
- msgstr "Laden von CSS verzögern?"
150
 
151
  #: classes/autoptimizeConfig.php:132
152
  msgid ""
153
- "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for "
154
- "mobile performance reasons having it deferred can be better."
155
  msgstr ""
156
- "Normalerweise wird CSS im &lt;head&gt;-Bereich der HTML-Seite geladen. Für "
157
- "die Performance in mobilen Browsern kann ein verzögertes Laden jedoch besser "
158
- "sein."
159
 
160
  #: classes/autoptimizeConfig.php:135
161
- msgid "Look for styles only in &lt;head&gt;?"
162
- msgstr "Nach CSS nur in &lt;head&gt; suchen?"
163
 
164
  #: classes/autoptimizeConfig.php:137
165
  msgid ""
166
- "Don't autoptimize CSS outside the head-section. If the cache gets big, you "
167
- "might want to enable this."
 
168
  msgstr ""
169
- "CSS außerhalb des head-Bereichs nicht optimieren. Die Aktivierung dieser "
170
- "Option kann sinnvoll sein, wenn der Cache sehr groß wird."
 
171
 
172
  #: classes/autoptimizeConfig.php:140
173
- msgid "Exclude CSS from autoptimize:"
174
- msgstr "Folgende CSS Dateien von Autoptimize ausschließen:"
175
 
176
  #: classes/autoptimizeConfig.php:142
177
  msgid ""
178
- "A comma-seperated list of CSS you want to exclude from being Autoptimized."
 
 
179
  msgstr ""
180
- "Eine mit Kommas getrennte Liste von CSS-Dateien die von der Optimierung "
181
- "durch Autoptimized augeschlossen werden sollen."
 
 
182
 
183
- #: classes/autoptimizeConfig.php:146
 
 
 
 
 
 
 
 
 
 
184
  msgid "CDN Options"
185
  msgstr "CDN Optionen"
186
 
187
- #: classes/autoptimizeConfig.php:149
188
  msgid "CDN Base URL"
189
  msgstr "CDN Basis URL:"
190
 
191
- #: classes/autoptimizeConfig.php:151
192
- msgid "Enter your CDN blog root directory URL if you want to enable CDN."
193
- msgstr "Gib hier die CDN Basis URL ein, wenn du CDN aktivieren möchtest."
 
 
 
 
194
 
195
- #: classes/autoptimizeConfig.php:155
196
  msgid "Cache Info"
197
  msgstr "Cache Info"
198
 
199
- #: classes/autoptimizeConfig.php:158
200
  msgid "Cache folder"
201
  msgstr "Cache Ordner:"
202
 
203
- #: classes/autoptimizeConfig.php:162
204
  msgid "Can we write?"
205
  msgstr "Schreibberechtigung?"
206
 
207
- #: classes/autoptimizeConfig.php:163
208
  msgid "Yes"
209
  msgstr "Ja"
210
 
211
- #: classes/autoptimizeConfig.php:163
212
  msgid "No"
213
  msgstr "Nein"
214
 
215
- #: classes/autoptimizeConfig.php:166
216
  msgid "Cached styles and scripts"
217
- msgstr "Gecachte CSS-Dateien und Skripte:"
218
 
219
- #: classes/autoptimizeConfig.php:170
220
  msgid "Save aggregated script/css as static files?"
221
- msgstr "Zusammengefügte CSS / Skript-Dateien als statische Dateien speichern?"
222
 
223
- #: classes/autoptimizeConfig.php:172
224
- msgid "Enable this if your webserver can handle the compression and expiry."
 
 
225
  msgstr ""
226
- "Aktiviere diese Option, wenn dein Webserver mit Komprimierung und HTTP-"
227
- "Expires umgehen kann."
 
228
 
229
- #: classes/autoptimizeConfig.php:178
230
  msgid "Save Changes"
231
  msgstr "Änderungen speichern"
232
 
233
- #: classes/autoptimizeConfig.php:179
234
  msgid "Save Changes and Empty Cache"
235
  msgstr "Änderungen speichern und Cache leeren"
236
 
237
- #: classes/autoptimizeConfig.php:185
238
- msgid "Do not donate for this plugin!"
239
- msgstr "Bitte nicht für dieses Plugin spenden!"
240
-
241
- #: classes/autoptimizeConfig.php:188
242
  msgid "futtta about"
243
  msgstr "Über futtta"
244
 
245
- #. #-#-#-#-# plugin.pot (Autoptimize 1.7.0) #-#-#-#-#
246
  #. Plugin Name of the plugin/theme
247
- #: classes/autoptimizeConfig.php:190
248
  msgid "Autoptimize"
249
  msgstr "Autoptimize"
250
 
251
- #: classes/autoptimizeConfig.php:191
252
  msgid "WordPress"
253
  msgstr "WordPress"
254
 
255
- #: classes/autoptimizeConfig.php:192
256
  msgid "Web Technology"
257
  msgstr "Web Technologien"
258
 
259
- #: classes/autoptimizeConfig.php:245
 
 
 
 
260
  msgid "Autoptimize Options"
261
  msgstr "Autoptimize Optionen"
262
 
263
- #: classes/autoptimizeConfig.php:291 classes/autoptimizeConfig.php:298
264
  msgid "Settings"
265
  msgstr "Einstellungen"
266
 
1
+ # Copyright (C) 2014 Autoptimize
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Autoptimize 1.8.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
+ "POT-Creation-Date: 2014-01-17 18:16:35+00:00\n"
 
 
 
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
11
+ "PO-Revision-Date: 2014-01-25 10:20+0100\n"
12
+ "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
+ "Language-Team: LANGUAGE <LL@li.org>\n"
14
  "X-Generator: Poedit 1.5.7\n"
15
 
16
+ #: autoptimize.php:117
17
  msgid ""
18
  "Thank you for installing and activating Autoptimize. Please configure it "
19
  "under \"Settings\" -> \"Autoptimize\" to start improving your site's "
23
  "konfiguriere das Plugin unter \"Einstellungen\" -> \"Autoptimize\" um die "
24
  "Performance deiner Webseite zu verbessern."
25
 
26
+ #: autoptimize.php:123
27
  msgid ""
28
  "Autoptimize has just been updated. Please <strong>test your site now</"
29
  "strong> and adapt Autoptimize config if needed."
37
 
38
  #: classes/autoptimizeConfig.php:62 classes/autoptimizeConfig.php:68
39
  msgid "Show advanced settings"
40
+ msgstr "Erweiterte Einstellungen einblenden"
41
 
42
  #: classes/autoptimizeConfig.php:63 classes/autoptimizeConfig.php:69
43
  msgid "Hide advanced settings"
44
+ msgstr "Erweiterte Einstellungen ausblenden"
45
 
46
  #: classes/autoptimizeConfig.php:77
47
  msgid "HTML Options"
60
  "Enable this if you want HTML comments to remain in the page, needed for e.g. "
61
  "AdSense to function properly."
62
  msgstr ""
63
+ "Aktiviere diese Option, wenn HTML Kommentare erhalten bleiben sollen, "
64
  "beispielsweise um AdSense einwandfrei zu kennzeichnen."
65
 
66
  #: classes/autoptimizeConfig.php:90
82
  "themes."
83
  msgstr ""
84
  "Aus Performance-Gründen ist es besser, JavaScript am Ende des HTML-Codes "
85
+ "einzufügen. Dies kann in manchen Fällen allerdings zu Problemen führen, "
86
+ "beispielsweise wenn Themes auf jQuery basieren."
87
 
88
  #: classes/autoptimizeConfig.php:102
89
  msgid "Look for scripts only in &lt;head&gt;?"
94
  "Mostly usefull in combination with previous option when using jQuery-based "
95
  "templates, but might help keeping cache size under control."
96
  msgstr ""
97
+ "Oft in Kombination mit den vorhergehenden Optionen nützlich, wenn "
98
+ "beispielsweise jQuery basierte Themes benutzt werden. Kann aber auch helfen "
99
+ "die Größe des Caches unter Kontrolle zu halten."
100
 
101
  #: classes/autoptimizeConfig.php:107
102
+ msgid "Exclude scripts from Autoptimize:"
103
  msgstr "Folgende Skripte von Autoptimize ausschließen:"
104
 
105
  #: classes/autoptimizeConfig.php:109
106
  msgid ""
107
+ "A comma-seperated list of scripts you want to exclude from being optimized, "
108
+ "for example 'whatever.js, another.js' (without the quotes) to exclude those "
109
+ "scripts from being aggregated and minimized by Autoptimize."
110
  msgstr ""
111
+ "Eine Komma getrennte Liste mit Skripten die von der Optimierung durch "
112
+ "Autoptimized ausgeschlossen werden sollen. Beispiel: 'whatever.js, another."
113
+ "js' (ohne Anführungszeichen)"
 
114
 
115
  #: classes/autoptimizeConfig.php:112
116
  msgid "Add try-catch wrapping?"
140
  "Enable this to include small background-images in the CSS itself instead of "
141
  "as seperate downloads."
142
  msgstr ""
143
+ "Aktiviere diese Option um kleine Bilder als Hintergrundbilder direkt in CSS "
144
+ "einzufügen. Dadurch werden Anfragen an den Webserver reduziert."
145
 
146
  #: classes/autoptimizeConfig.php:130
147
+ msgid "Look for styles only in &lt;head&gt;?"
148
+ msgstr "Nach CSS nur in &lt;head&gt; suchen?"
149
 
150
  #: classes/autoptimizeConfig.php:132
151
  msgid ""
152
+ "Don't autoptimize CSS outside the head-section. If the cache gets big, you "
153
+ "might want to enable this."
154
  msgstr ""
155
+ "Optimiere CSS nicht außerhalb des head-Bereichs. Die Aktivierung dieser "
156
+ "Option kann sinnvoll sein, wenn der Cache sehr groß wird."
 
157
 
158
  #: classes/autoptimizeConfig.php:135
159
+ msgid "Defer CSS loading?"
160
+ msgstr "Laden von CSS verzögern?"
161
 
162
  #: classes/autoptimizeConfig.php:137
163
  msgid ""
164
+ "Load optimized CSS only after page load (disables CSS inlining). "
165
+ "<strong>Warning</strong>: <a href=\"http://wordpress.org/plugins/autoptimize/"
166
+ "faq/\" target=\"_blank\">check the FAQ</a> before activating this option!"
167
  msgstr ""
168
+ "Lade optimiertes CSS erst nach dem Seitenaufbau (deaktiviert CSS Inlining). "
169
+ "<strong>Warnung</strong>: <a href=\"http://wordpress.org/plugins/autoptimize/"
170
+ "faq/\" target=\"_blank\">Lese die FAQ</a> vor der Aktivierung dieser Option."
171
 
172
  #: classes/autoptimizeConfig.php:140
173
+ msgid "Inline all CSS?"
174
+ msgstr "CSS Inlining aktivieren?"
175
 
176
  #: classes/autoptimizeConfig.php:142
177
  msgid ""
178
+ "Inlining all CSS can improve performance for sites with a low pageviews/ "
179
+ "visitor-rate, but may slow down performance otherwise. CSS inlining disables "
180
+ "CSS deferring."
181
  msgstr ""
182
+ "CSS Inlining kann die Performance von Webseiten mit geringen "
183
+ "Seitenaufrufen / Besucherzahlen verbessern. In anderen Situation kann diese "
184
+ "Option allerdings die Performance verschlechtern. CSS Inlining deaktiviert "
185
+ "das verzögerte Laden von CSS."
186
 
187
+ #: classes/autoptimizeConfig.php:145
188
+ msgid "Exclude CSS from Autoptimize:"
189
+ msgstr "Folgende CSS-Dateien von Autoptimize ausschließen:"
190
+
191
+ #: classes/autoptimizeConfig.php:147
192
+ msgid "A comma-seperated list of CSS you want to exclude from being optimized."
193
+ msgstr ""
194
+ "Eine Komma getrennte Liste mit CSS-Dateien die von der Optimierung "
195
+ "ausgeschlossen werden sollen."
196
+
197
+ #: classes/autoptimizeConfig.php:151
198
  msgid "CDN Options"
199
  msgstr "CDN Optionen"
200
 
201
+ #: classes/autoptimizeConfig.php:154
202
  msgid "CDN Base URL"
203
  msgstr "CDN Basis URL:"
204
 
205
+ #: classes/autoptimizeConfig.php:156
206
+ msgid ""
207
+ "Enter your CDN blog root directory URL if you want to enable CDN for images "
208
+ "referenced in the CSS."
209
+ msgstr ""
210
+ "Gib hier die URL deines CDN Root-Verzeichnisses ein, wenn du CDN für Bilder "
211
+ "und referenzierte CSS-Dateien aktivieren möchtest."
212
 
213
+ #: classes/autoptimizeConfig.php:160
214
  msgid "Cache Info"
215
  msgstr "Cache Info"
216
 
217
+ #: classes/autoptimizeConfig.php:163
218
  msgid "Cache folder"
219
  msgstr "Cache Ordner:"
220
 
221
+ #: classes/autoptimizeConfig.php:167
222
  msgid "Can we write?"
223
  msgstr "Schreibberechtigung?"
224
 
225
+ #: classes/autoptimizeConfig.php:168
226
  msgid "Yes"
227
  msgstr "Ja"
228
 
229
+ #: classes/autoptimizeConfig.php:168
230
  msgid "No"
231
  msgstr "Nein"
232
 
233
+ #: classes/autoptimizeConfig.php:171
234
  msgid "Cached styles and scripts"
235
+ msgstr "Anzahl gecachter Dateien:"
236
 
237
+ #: classes/autoptimizeConfig.php:175
238
  msgid "Save aggregated script/css as static files?"
239
+ msgstr "Optimierte CSS / Skript-Dateien als statische Dateien speichern?"
240
 
241
+ #: classes/autoptimizeConfig.php:177
242
+ msgid ""
243
+ "By default files saved are static css/js, uncheck this option if your "
244
+ "webserver doesn't properly handle the compression and expiry."
245
  msgstr ""
246
+ "Standardmäßig werden CSS- und JavaScript-Dateien bereits statisch "
247
+ "gespeichert. Deaktiviere diese Option, wenn dein Webserver mit der "
248
+ "Verarbeitung von komprimierten Dateien und Expires-Header Probleme hat."
249
 
250
+ #: classes/autoptimizeConfig.php:183
251
  msgid "Save Changes"
252
  msgstr "Änderungen speichern"
253
 
254
+ #: classes/autoptimizeConfig.php:184
255
  msgid "Save Changes and Empty Cache"
256
  msgstr "Änderungen speichern und Cache leeren"
257
 
258
+ #: classes/autoptimizeConfig.php:192
 
 
 
 
259
  msgid "futtta about"
260
  msgstr "Über futtta"
261
 
262
+ #. #-#-#-#-# plugin.pot (Autoptimize 1.8.0) #-#-#-#-#
263
  #. Plugin Name of the plugin/theme
264
+ #: classes/autoptimizeConfig.php:194
265
  msgid "Autoptimize"
266
  msgstr "Autoptimize"
267
 
268
+ #: classes/autoptimizeConfig.php:195
269
  msgid "WordPress"
270
  msgstr "WordPress"
271
 
272
+ #: classes/autoptimizeConfig.php:196
273
  msgid "Web Technology"
274
  msgstr "Web Technologien"
275
 
276
+ #: classes/autoptimizeConfig.php:201
277
+ msgid "Do not donate for this plugin!"
278
+ msgstr "Bitte spende nicht für dieses Plugin!"
279
+
280
+ #: classes/autoptimizeConfig.php:262
281
  msgid "Autoptimize Options"
282
  msgstr "Autoptimize Optionen"
283
 
284
+ #: classes/autoptimizeConfig.php:309 classes/autoptimizeConfig.php:316
285
  msgid "Settings"
286
  msgstr "Einstellungen"
287
 
localization/autoptimize-fa_IR.mo CHANGED
Binary file
localization/autoptimize-fa_IR.po CHANGED
@@ -4,18 +4,18 @@ msgid ""
4
  msgstr ""
5
  "Project-Id-Version: Autoptimize 1.7.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
- "POT-Creation-Date: 2013-10-21 07:38:13+00:00\n"
8
- "PO-Revision-Date: 2013-10-21 21:19+0330\n"
9
  "Last-Translator: Hamed.T <ham3d.t@gmail.com>\n"
10
  "Language-Team: http://basics.ir/ <ham3d.t@gmail.com>\n"
11
- "Language: Persian\n"
12
  "MIME-Version: 1.0\n"
13
  "Content-Type: text/plain; charset=UTF-8\n"
14
  "Content-Transfer-Encoding: 8bit\n"
15
- "X-Generator: Poedit 1.5.7\n"
16
  "X-Poedit-SourceCharset: UTF-8\n"
17
 
18
- #: autoptimize.php:66
19
  msgid ""
20
  "Thank you for installing and activating Autoptimize. Please configure it "
21
  "under \"Settings\" -> \"Autoptimize\" to start improving your site's "
@@ -25,7 +25,7 @@ msgstr ""
25
  "مسیر \"تنظیمات > Autoptimize\" انجام دهید تا کارایی و سرعت سایت شما افزایش "
26
  "یابد."
27
 
28
- #: autoptimize.php:72
29
  msgid ""
30
  "Autoptimize has just been updated. Please <strong>test your site now</"
31
  "strong> and adapt Autoptimize config if needed."
@@ -99,14 +99,16 @@ msgstr ""
99
  "باشید."
100
 
101
  #: classes/autoptimizeConfig.php:107
102
- msgid "Exclude scripts from autoptimize:"
 
103
  msgstr "جلوگیری از بهینه سازی اسکریپت ها:"
104
 
105
  #: classes/autoptimizeConfig.php:109
 
106
  msgid ""
107
- "A comma-seperated list of scripts you want to exclude from being "
108
- "Autoptimized, for example 'whatever.js, another.js' (without the quotes) to "
109
- "exclude those scripts from being aggregated and minimized by Autoptimize."
110
  msgstr ""
111
  "برای جلوگیری از بهینه سازی اسکریپت ها لیستی از اسکریپت ها را با استفاده از "
112
  "کاما از هم جدا کنید و در فیلد زیر وارد کنید. مانند: whatever.js, another.js"
@@ -143,122 +145,145 @@ msgstr ""
143
  "جداگانه بارگذاری شود توسط data URI همراه با فایل CSS بارگذاری می شوند."
144
 
145
  #: classes/autoptimizeConfig.php:130
146
- msgid "Defer CSS loading?"
147
- msgstr "به تاخیر انداختن بارگذاری CSS?"
148
 
149
  #: classes/autoptimizeConfig.php:132
150
  msgid ""
151
- "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for "
152
- "mobile performance reasons having it deferred can be better."
153
  msgstr ""
154
- "در حالت عادی CSS در قسمت &lt;head&gt; بارگذاری می شود، اما برای افزایش "
155
- "کارایی در گوشی های همراه بهتر است که با تاخیر بارگذاری شوند."
156
 
157
  #: classes/autoptimizeConfig.php:135
158
- msgid "Look for styles only in &lt;head&gt;?"
159
- msgstr "فقط استایل هایی که در قسمت &lt;head&gt; هستند بهینه سازی شوند؟"
160
 
161
  #: classes/autoptimizeConfig.php:137
162
  msgid ""
163
- "Don't autoptimize CSS outside the head-section. If the cache gets big, you "
164
- "might want to enable this."
 
165
  msgstr ""
166
- "استایل هایی که خارج از قسمت head هستند بهینه سازی نمی شوند. اگر حجم کش زیاد "
167
- "باشد شاید مایل باشید تا از این گزینه استفاده کنید."
 
 
168
 
169
  #: classes/autoptimizeConfig.php:140
170
- msgid "Exclude CSS from autoptimize:"
171
- msgstr "جلوگیری از بهینه سازی CSS ها:"
172
 
173
  #: classes/autoptimizeConfig.php:142
174
  msgid ""
175
- "A comma-seperated list of CSS you want to exclude from being Autoptimized."
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
176
  msgstr ""
177
  "با استفاده از کاما لیست فایل های CSS ایی که می خواهید از بهینه سازی آن ها "
178
  "جلوگیری شود در فیلد زیر وارد کنید."
179
 
180
- #: classes/autoptimizeConfig.php:146
181
  msgid "CDN Options"
182
  msgstr "تنظیمات CDN"
183
 
184
- #: classes/autoptimizeConfig.php:149
185
  msgid "CDN Base URL"
186
  msgstr "آدرس پایه CDN"
187
 
188
- #: classes/autoptimizeConfig.php:151
189
- msgid "Enter your CDN blog root directory URL if you want to enable CDN."
 
 
 
190
  msgstr ""
191
  "اگر می خواهید CDN فعال شود آدرس CDN ریشه دایرکتوری بلاگ خود را وارد کنید."
192
 
193
- #: classes/autoptimizeConfig.php:155
194
  msgid "Cache Info"
195
  msgstr "اطلاعات کش"
196
 
197
- #: classes/autoptimizeConfig.php:158
198
  msgid "Cache folder"
199
  msgstr "فولدر کش"
200
 
201
- #: classes/autoptimizeConfig.php:162
202
  msgid "Can we write?"
203
  msgstr "حق نوشتن (write) داریم؟"
204
 
205
- #: classes/autoptimizeConfig.php:163
206
  msgid "Yes"
207
  msgstr "بله"
208
 
209
- #: classes/autoptimizeConfig.php:163
210
  msgid "No"
211
  msgstr "خیر"
212
 
213
- #: classes/autoptimizeConfig.php:166
214
  msgid "Cached styles and scripts"
215
  msgstr "استایل ها و اسکریپت های کش شده"
216
 
217
- #: classes/autoptimizeConfig.php:170
218
  msgid "Save aggregated script/css as static files?"
219
  msgstr "جمع و ذخیره اسکریپت/CSS در یک فایل ثابت(static)؟"
220
 
221
- #: classes/autoptimizeConfig.php:172
222
- msgid "Enable this if your webserver can handle the compression and expiry."
 
 
 
223
  msgstr ""
224
  "اگر وب سرور شما می تواند فشرده سازی و کش فایل ها را انجام دهد این گزینه را "
225
  "فعال کنید."
226
 
227
- #: classes/autoptimizeConfig.php:178
228
  msgid "Save Changes"
229
  msgstr "ذخیره تغییرات"
230
 
231
- #: classes/autoptimizeConfig.php:179
232
  msgid "Save Changes and Empty Cache"
233
  msgstr "ذخیره تغییرات و تخلیه کش"
234
 
235
- #: classes/autoptimizeConfig.php:185
236
- msgid "Do not donate for this plugin!"
237
- msgstr "به این افزونه کمک مالی نکنید!"
238
-
239
- #: classes/autoptimizeConfig.php:188
240
  msgid "futtta about"
241
  msgstr "درباره ی futtta"
242
 
243
- #. #-#-#-#-# plugin.pot (Autoptimize 1.7.0) #-#-#-#-#
244
  #. Plugin Name of the plugin/theme
245
- #: classes/autoptimizeConfig.php:190
246
  msgid "Autoptimize"
247
  msgstr "Autoptimize"
248
 
249
- #: classes/autoptimizeConfig.php:191
250
  msgid "WordPress"
251
  msgstr "وردپرس"
252
 
253
- #: classes/autoptimizeConfig.php:192
254
  msgid "Web Technology"
255
  msgstr "تکنولوژی وب"
256
 
257
- #: classes/autoptimizeConfig.php:245
 
 
 
 
258
  msgid "Autoptimize Options"
259
  msgstr "تنظیمات Autoptimize"
260
 
261
- #: classes/autoptimizeConfig.php:291 classes/autoptimizeConfig.php:298
262
  msgid "Settings"
263
  msgstr "تنظیمات"
264
 
@@ -282,6 +307,13 @@ msgstr "Frank Goossens (futtta)"
282
  msgid "http://blog.futtta.be/"
283
  msgstr "http://blog.futtta.be/"
284
 
 
 
 
 
 
 
 
285
  #~ msgid "Do not compress cache files"
286
  #~ msgstr "فایل های کش را فشرده سازی نکن"
287
 
4
  msgstr ""
5
  "Project-Id-Version: Autoptimize 1.7.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
+ "POT-Creation-Date: 2014-01-17 18:16:35+00:00\n"
8
+ "PO-Revision-Date: 2014-01-18 23:12+0330\n"
9
  "Last-Translator: Hamed.T <ham3d.t@gmail.com>\n"
10
  "Language-Team: http://basics.ir/ <ham3d.t@gmail.com>\n"
11
+ "Language: fa\n"
12
  "MIME-Version: 1.0\n"
13
  "Content-Type: text/plain; charset=UTF-8\n"
14
  "Content-Transfer-Encoding: 8bit\n"
15
+ "X-Generator: Poedit 1.6.3\n"
16
  "X-Poedit-SourceCharset: UTF-8\n"
17
 
18
+ #: autoptimize.php:117
19
  msgid ""
20
  "Thank you for installing and activating Autoptimize. Please configure it "
21
  "under \"Settings\" -> \"Autoptimize\" to start improving your site's "
25
  "مسیر \"تنظیمات > Autoptimize\" انجام دهید تا کارایی و سرعت سایت شما افزایش "
26
  "یابد."
27
 
28
+ #: autoptimize.php:123
29
  msgid ""
30
  "Autoptimize has just been updated. Please <strong>test your site now</"
31
  "strong> and adapt Autoptimize config if needed."
99
  "باشید."
100
 
101
  #: classes/autoptimizeConfig.php:107
102
+ #, fuzzy
103
+ msgid "Exclude scripts from Autoptimize:"
104
  msgstr "جلوگیری از بهینه سازی اسکریپت ها:"
105
 
106
  #: classes/autoptimizeConfig.php:109
107
+ #, fuzzy
108
  msgid ""
109
+ "A comma-seperated list of scripts you want to exclude from being optimized, "
110
+ "for example 'whatever.js, another.js' (without the quotes) to exclude those "
111
+ "scripts from being aggregated and minimized by Autoptimize."
112
  msgstr ""
113
  "برای جلوگیری از بهینه سازی اسکریپت ها لیستی از اسکریپت ها را با استفاده از "
114
  "کاما از هم جدا کنید و در فیلد زیر وارد کنید. مانند: whatever.js, another.js"
145
  "جداگانه بارگذاری شود توسط data URI همراه با فایل CSS بارگذاری می شوند."
146
 
147
  #: classes/autoptimizeConfig.php:130
148
+ msgid "Look for styles only in &lt;head&gt;?"
149
+ msgstr "فقط استایل هایی که در قسمت &lt;head&gt; هستند بهینه سازی شوند؟"
150
 
151
  #: classes/autoptimizeConfig.php:132
152
  msgid ""
153
+ "Don't autoptimize CSS outside the head-section. If the cache gets big, you "
154
+ "might want to enable this."
155
  msgstr ""
156
+ "استایل هایی که خارج از قسمت head هستند بهینه سازی نمی شوند. اگر حجم کش زیاد "
157
+ "باشد شاید مایل باشید تا از این گزینه استفاده کنید."
158
 
159
  #: classes/autoptimizeConfig.php:135
160
+ msgid "Defer CSS loading?"
161
+ msgstr "به تاخیر انداختن بارگذاری CSS?"
162
 
163
  #: classes/autoptimizeConfig.php:137
164
  msgid ""
165
+ "Load optimized CSS only after page load (disables CSS inlining). "
166
+ "<strong>Warning</strong>: <a href=\"http://wordpress.org/plugins/autoptimize/"
167
+ "faq/\" target=\"_blank\">check the FAQ</a> before activating this option!"
168
  msgstr ""
169
+ "CSS بهینه شده بعد از بارگذاری صفحه بارگذاری خواهد شد (CSS درون خطی را "
170
+ "غیرفعال می‌کند). <strong>هشدار</strong>: قبل از فعال سازی این گزینه<a href="
171
+ "\"http://wordpress.org/plugins/autoptimize/faq/\" target=\"_blank\">سوالات "
172
+ "متداول</a> را مطالعه فرمایید!"
173
 
174
  #: classes/autoptimizeConfig.php:140
175
+ msgid "Inline all CSS?"
176
+ msgstr "تبدیل CSS به درون خطی"
177
 
178
  #: classes/autoptimizeConfig.php:142
179
  msgid ""
180
+ "Inlining all CSS can improve performance for sites with a low pageviews/ "
181
+ "visitor-rate, but may slow down performance otherwise. CSS inlining disables "
182
+ "CSS deferring."
183
+ msgstr ""
184
+ "درون خطی نمودن کدهای CSS باعث افزایش سرعت سایت هایی با بازدید کم می‌شود، در "
185
+ "غیر اینصورت ممکن است باعث کم شدن سرعت بارگذاری شود. درون خطی نمودن کدهای CSS "
186
+ "گزینه به تاخیر انداختن بارگذاری CSS را غیرفعال می کند."
187
+
188
+ #: classes/autoptimizeConfig.php:145
189
+ #, fuzzy
190
+ msgid "Exclude CSS from Autoptimize:"
191
+ msgstr "جلوگیری از بهینه سازی CSS ها:"
192
+
193
+ #: classes/autoptimizeConfig.php:147
194
+ #, fuzzy
195
+ msgid "A comma-seperated list of CSS you want to exclude from being optimized."
196
  msgstr ""
197
  "با استفاده از کاما لیست فایل های CSS ایی که می خواهید از بهینه سازی آن ها "
198
  "جلوگیری شود در فیلد زیر وارد کنید."
199
 
200
+ #: classes/autoptimizeConfig.php:151
201
  msgid "CDN Options"
202
  msgstr "تنظیمات CDN"
203
 
204
+ #: classes/autoptimizeConfig.php:154
205
  msgid "CDN Base URL"
206
  msgstr "آدرس پایه CDN"
207
 
208
+ #: classes/autoptimizeConfig.php:156
209
+ #, fuzzy
210
+ msgid ""
211
+ "Enter your CDN blog root directory URL if you want to enable CDN for images "
212
+ "referenced in the CSS."
213
  msgstr ""
214
  "اگر می خواهید CDN فعال شود آدرس CDN ریشه دایرکتوری بلاگ خود را وارد کنید."
215
 
216
+ #: classes/autoptimizeConfig.php:160
217
  msgid "Cache Info"
218
  msgstr "اطلاعات کش"
219
 
220
+ #: classes/autoptimizeConfig.php:163
221
  msgid "Cache folder"
222
  msgstr "فولدر کش"
223
 
224
+ #: classes/autoptimizeConfig.php:167
225
  msgid "Can we write?"
226
  msgstr "حق نوشتن (write) داریم؟"
227
 
228
+ #: classes/autoptimizeConfig.php:168
229
  msgid "Yes"
230
  msgstr "بله"
231
 
232
+ #: classes/autoptimizeConfig.php:168
233
  msgid "No"
234
  msgstr "خیر"
235
 
236
+ #: classes/autoptimizeConfig.php:171
237
  msgid "Cached styles and scripts"
238
  msgstr "استایل ها و اسکریپت های کش شده"
239
 
240
+ #: classes/autoptimizeConfig.php:175
241
  msgid "Save aggregated script/css as static files?"
242
  msgstr "جمع و ذخیره اسکریپت/CSS در یک فایل ثابت(static)؟"
243
 
244
+ #: classes/autoptimizeConfig.php:177
245
+ #, fuzzy
246
+ msgid ""
247
+ "By default files saved are static css/js, uncheck this option if your "
248
+ "webserver doesn't properly handle the compression and expiry."
249
  msgstr ""
250
  "اگر وب سرور شما می تواند فشرده سازی و کش فایل ها را انجام دهد این گزینه را "
251
  "فعال کنید."
252
 
253
+ #: classes/autoptimizeConfig.php:183
254
  msgid "Save Changes"
255
  msgstr "ذخیره تغییرات"
256
 
257
+ #: classes/autoptimizeConfig.php:184
258
  msgid "Save Changes and Empty Cache"
259
  msgstr "ذخیره تغییرات و تخلیه کش"
260
 
261
+ #: classes/autoptimizeConfig.php:192
 
 
 
 
262
  msgid "futtta about"
263
  msgstr "درباره ی futtta"
264
 
 
265
  #. Plugin Name of the plugin/theme
266
+ #: classes/autoptimizeConfig.php:194
267
  msgid "Autoptimize"
268
  msgstr "Autoptimize"
269
 
270
+ #: classes/autoptimizeConfig.php:195
271
  msgid "WordPress"
272
  msgstr "وردپرس"
273
 
274
+ #: classes/autoptimizeConfig.php:196
275
  msgid "Web Technology"
276
  msgstr "تکنولوژی وب"
277
 
278
+ #: classes/autoptimizeConfig.php:201
279
+ msgid "Do not donate for this plugin!"
280
+ msgstr "به این افزونه کمک مالی نکنید!"
281
+
282
+ #: classes/autoptimizeConfig.php:262
283
  msgid "Autoptimize Options"
284
  msgstr "تنظیمات Autoptimize"
285
 
286
+ #: classes/autoptimizeConfig.php:309 classes/autoptimizeConfig.php:316
287
  msgid "Settings"
288
  msgstr "تنظیمات"
289
 
307
  msgid "http://blog.futtta.be/"
308
  msgstr "http://blog.futtta.be/"
309
 
310
+ #~ msgid ""
311
+ #~ "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for "
312
+ #~ "mobile performance reasons having it deferred can be better."
313
+ #~ msgstr ""
314
+ #~ "در حالت عادی CSS در قسمت &lt;head&gt; بارگذاری می شود، اما برای افزایش "
315
+ #~ "کارایی در گوشی های همراه بهتر است که با تاخیر بارگذاری شوند."
316
+
317
  #~ msgid "Do not compress cache files"
318
  #~ msgstr "فایل های کش را فشرده سازی نکن"
319
 
localization/autoptimize-fr_FR.mo CHANGED
Binary file
localization/autoptimize-fr_FR.po CHANGED
@@ -2,46 +2,37 @@
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Autoptimize 1.7.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
- "POT-Creation-Date: 2013-10-21 07:38:13+00:00\n"
8
- "PO-Revision-Date: 2013-10-21 10:54+0100\n"
9
- "Last-Translator: Nico - WordPress Hébergement <contact@wordpress-hebergement."
10
- "fr>\n"
11
  "Language-Team: WordPress Hébergement <contact@wordpress-hebergement.fr>\n"
12
- "Language: FR\n"
13
  "MIME-Version: 1.0\n"
14
  "Content-Type: text/plain; charset=UTF-8\n"
15
  "Content-Transfer-Encoding: 8bit\n"
 
16
  "X-Generator: Poedit 1.5.7\n"
17
 
18
- #: autoptimize.php:66
19
- msgid ""
20
- "Thank you for installing and activating Autoptimize. Please configure it "
21
- "under \"Settings\" -> \"Autoptimize\" to start improving your site's "
22
- "performance."
23
- msgstr ""
24
- "Merci d'avoir installé et activé Autoptimize. Vous pouvez maintenant le "
25
- "paramétrer via \"Réglages\" -> \"Autoptimize\" et commencer à améliorer les "
26
- "performances de votre site"
27
 
28
- #: autoptimize.php:72
29
- msgid ""
30
- "Autoptimize has just been updated. Please <strong>test your site now</"
31
- "strong> and adapt Autoptimize config if needed."
32
- msgstr ""
33
- "Autoptimize vient d'être mis à jour. Vous pouvez maintenant <trong>tester "
34
- "votre site</strong> et adapter si besoin les paramètres d'Autoptimize."
35
 
36
  #: classes/autoptimizeConfig.php:56
37
  msgid "Autoptimize Settings"
38
  msgstr "Configuration d'Autoptimize"
39
 
40
- #: classes/autoptimizeConfig.php:62 classes/autoptimizeConfig.php:68
 
41
  msgid "Show advanced settings"
42
  msgstr "Afficher les paramètres avancés"
43
 
44
- #: classes/autoptimizeConfig.php:63 classes/autoptimizeConfig.php:69
 
45
  msgid "Hide advanced settings"
46
  msgstr "Cacher les paramètres avancés"
47
 
@@ -58,12 +49,8 @@ msgid "Keep HTML comments?"
58
  msgstr "Préserver les commentaires HTML"
59
 
60
  #: classes/autoptimizeConfig.php:86
61
- msgid ""
62
- "Enable this if you want HTML comments to remain in the page, needed for e.g. "
63
- "AdSense to function properly."
64
- msgstr ""
65
- "Sélectionnez cette option si vous souhaitez que vos commentaires HTML "
66
- "restent dans la page (nécessaire par exemple pour qu'Adsense fonctionne)"
67
 
68
  #: classes/autoptimizeConfig.php:90
69
  msgid "JavaScript Options"
@@ -78,53 +65,32 @@ msgid "Force JavaScript in &lt;head&gt;?"
78
  msgstr "Forcer le JavaScript à charger dans l'en-tête de la page ?"
79
 
80
  #: classes/autoptimizeConfig.php:99
81
- msgid ""
82
- "For performance reasons it is better to include JavaScript at the bottom of "
83
- "HTML, but this sometimes breaks things. Especially useful for jQuery-based "
84
- "themes."
85
- msgstr ""
86
- "Pour améliorer les performances, il est préférable d'inclure le JavaScript à "
87
- "la fin du code HTML, mais cela peut parfois 'casser' certaines pages "
88
- "(notamment pour les thèmes à base de jQuery)."
89
 
90
  #: classes/autoptimizeConfig.php:102
91
  msgid "Look for scripts only in &lt;head&gt;?"
92
  msgstr "Chercher les scripts uniquement dans l'en-tête ?"
93
 
94
  #: classes/autoptimizeConfig.php:104
95
- msgid ""
96
- "Mostly usefull in combination with previous option when using jQuery-based "
97
- "templates, but might help keeping cache size under control."
98
- msgstr ""
99
- "Surtout utile combiné aux précédentes options lorsque vous utilisez des "
100
- "templates à base de jQuery, mais peut aussi permettre de diminuer la taille "
101
- "du cache."
102
 
103
  #: classes/autoptimizeConfig.php:107
104
- msgid "Exclude scripts from autoptimize:"
105
  msgstr "Scripts à exclure d'Autoptimize"
106
 
107
  #: classes/autoptimizeConfig.php:109
108
- msgid ""
109
- "A comma-seperated list of scripts you want to exclude from being "
110
- "Autoptimized, for example 'whatever.js, another.js' (without the quotes) to "
111
- "exclude those scripts from being aggregated and minimized by Autoptimize."
112
- msgstr ""
113
- "Liste des scripts - séparés par des virgules - que vous ne souhaitez pas "
114
- "Autoptimiser. Par exemple: 'monscript.js, monautrescript.js' (sans les "
115
- "gullemets) pour exclure ces scripts de l'aggrégation et la compression "
116
- "réalisée par Autoptimize."
117
 
118
  #: classes/autoptimizeConfig.php:112
119
  msgid "Add try-catch wrapping?"
120
  msgstr "Ajouter une gestion des erreurs (trycatch) ?"
121
 
122
  #: classes/autoptimizeConfig.php:114
123
- msgid ""
124
- "If your scripts break because of an script error, you might want to try this."
125
- msgstr ""
126
- "Si votre script est 'cassé' par des erreurs, vous pouvez essayer cette "
127
- "option."
128
 
129
  #: classes/autoptimizeConfig.php:118
130
  msgid "CSS Options"
@@ -139,132 +105,121 @@ msgid "Generate data: URIs for images?"
139
  msgstr "Génération de données: URI pour les images?"
140
 
141
  #: classes/autoptimizeConfig.php:127
142
- msgid ""
143
- "Enable this to include small background-images in the CSS itself instead of "
144
- "as seperate downloads."
145
- msgstr ""
146
- "Sélectionnez cette option pour inclure les petites images de fond dans le "
147
- "CSS lui-même au lieu d'un chargement séparé."
148
 
149
  #: classes/autoptimizeConfig.php:130
150
- msgid "Defer CSS loading?"
151
- msgstr "Reporter le chargement des CSS"
152
 
153
  #: classes/autoptimizeConfig.php:132
154
- msgid ""
155
- "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for "
156
- "mobile performance reasons having it deferred can be better."
157
- msgstr ""
158
- "Normalement, les CSS sont chargés dans l'en-tête du code HTML, mais pour "
159
- "améliorer les performances de lecture par un terminal mobile, il peut être "
160
- "préférable de reporter ce chargement."
161
 
162
  #: classes/autoptimizeConfig.php:135
163
- msgid "Look for styles only in &lt;head&gt;?"
164
- msgstr "Ne rechercher les styles que dans l'en-tête ?"
165
 
166
  #: classes/autoptimizeConfig.php:137
167
- msgid ""
168
- "Don't autoptimize CSS outside the head-section. If the cache gets big, you "
169
- "might want to enable this."
170
- msgstr ""
171
- "N'optimise pas les CSS situés en dehors de l'en-tête. Si votre cache devient "
172
- "trop important, vous pouvez utliser cette option."
173
 
174
  #: classes/autoptimizeConfig.php:140
175
- msgid "Exclude CSS from autoptimize:"
176
- msgstr "Exclure ces CSS d'Autoptimise."
177
 
178
  #: classes/autoptimizeConfig.php:142
179
- msgid ""
180
- "A comma-seperated list of CSS you want to exclude from being Autoptimized."
181
- msgstr ""
182
- "Liste des fichiers CSS - spérarés par des virgules - que vous souhaitez "
183
- "exclure de l'Autoptimisation."
 
 
 
 
 
184
 
185
- #: classes/autoptimizeConfig.php:146
186
  msgid "CDN Options"
187
  msgstr "Options CDN"
188
 
189
- #: classes/autoptimizeConfig.php:149
190
  msgid "CDN Base URL"
191
  msgstr "Base URL du CDN"
192
 
193
- #: classes/autoptimizeConfig.php:151
194
- msgid "Enter your CDN blog root directory URL if you want to enable CDN."
195
- msgstr ""
196
- "Saisissez l'URL du répertoire racine de votre site si vous souhaitez "
197
- "utiliser un CDN."
198
 
199
- #: classes/autoptimizeConfig.php:155
200
  msgid "Cache Info"
201
  msgstr "Informations du cache"
202
 
203
- #: classes/autoptimizeConfig.php:158
204
  msgid "Cache folder"
205
  msgstr "Répertoire du cache"
206
 
207
- #: classes/autoptimizeConfig.php:162
208
  msgid "Can we write?"
209
  msgstr "Droits d'écriture ?"
210
 
211
- #: classes/autoptimizeConfig.php:163
212
  msgid "Yes"
213
  msgstr "Oui"
214
 
215
- #: classes/autoptimizeConfig.php:163
216
  msgid "No"
217
  msgstr "Non"
218
 
219
- #: classes/autoptimizeConfig.php:166
220
  msgid "Cached styles and scripts"
221
  msgstr "Styles et scripts en cache"
222
 
223
- #: classes/autoptimizeConfig.php:170
224
  msgid "Save aggregated script/css as static files?"
225
  msgstr "Enregistrer les scripts/css en tant que fichiers statiques ?"
226
 
227
- #: classes/autoptimizeConfig.php:172
228
- msgid "Enable this if your webserver can handle the compression and expiry."
229
- msgstr ""
230
- "Sélectionnez cette option si votre serveur peut gérer la compression et "
231
- "l'expiration des fichiers."
232
 
233
- #: classes/autoptimizeConfig.php:178
234
  msgid "Save Changes"
235
  msgstr "Enregistrer les modifications"
236
 
237
- #: classes/autoptimizeConfig.php:179
238
  msgid "Save Changes and Empty Cache"
239
  msgstr "Enregistrer les modifications et vider le cache"
240
 
241
- #: classes/autoptimizeConfig.php:185
242
- msgid "Do not donate for this plugin!"
243
- msgstr "Ne faites pas de don pas pour ce plugin!"
244
-
245
- #: classes/autoptimizeConfig.php:188
246
  msgid "futtta about"
247
  msgstr "futta à propos de"
248
 
249
- #. #-#-#-#-# plugin.pot (Autoptimize 1.7.0) #-#-#-#-#
250
  #. Plugin Name of the plugin/theme
251
- #: classes/autoptimizeConfig.php:190
252
  msgid "Autoptimize"
253
  msgstr "Autoptimize"
254
 
255
- #: classes/autoptimizeConfig.php:191
256
  msgid "WordPress"
257
  msgstr "WordPress"
258
 
259
- #: classes/autoptimizeConfig.php:192
260
  msgid "Web Technology"
261
  msgstr "La technologie Web"
262
 
263
- #: classes/autoptimizeConfig.php:245
 
 
 
 
264
  msgid "Autoptimize Options"
265
  msgstr "Options Autoptimize "
266
 
267
- #: classes/autoptimizeConfig.php:291 classes/autoptimizeConfig.php:298
 
268
  msgid "Settings"
269
  msgstr "Paramètres"
270
 
@@ -273,12 +228,8 @@ msgid "http://blog.futtta.be/autoptimize"
273
  msgstr "http://blog.futtta.be/autoptimize"
274
 
275
  #. Description of the plugin/theme
276
- msgid ""
277
- "Optimizes your website, concatenating the CSS and JavaScript code, and "
278
- "compressing it."
279
- msgstr ""
280
- "Optimise votre site web en rassemblant les CSS et JavaScript et en les "
281
- "compressant."
282
 
283
  #. Author of the plugin/theme
284
  msgid "Frank Goossens (futtta)"
@@ -287,3 +238,11 @@ msgstr "Frank Goossens (futtta)"
287
  #. Author URI of the plugin/theme
288
  msgid "http://blog.futtta.be/"
289
  msgstr "http://blog.futtta.be/"
 
 
 
 
 
 
 
 
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Autoptimize 1.8.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
+ "POT-Creation-Date: 2014-01-17 18:16:35+00:00\n"
8
+ "PO-Revision-Date: 2014-01-22 08:34+0100\n"
9
+ "Last-Translator: frank goossens <futtta@gmail.com>\n"
 
10
  "Language-Team: WordPress Hébergement <contact@wordpress-hebergement.fr>\n"
 
11
  "MIME-Version: 1.0\n"
12
  "Content-Type: text/plain; charset=UTF-8\n"
13
  "Content-Transfer-Encoding: 8bit\n"
14
+ "Language: FR\n"
15
  "X-Generator: Poedit 1.5.7\n"
16
 
17
+ #: autoptimize.php:117
18
+ msgid "Thank you for installing and activating Autoptimize. Please configure it under \"Settings\" -> \"Autoptimize\" to start improving your site's performance."
19
+ msgstr "Merci d'avoir installé et activé Autoptimize. Vous pouvez maintenant le paramétrer via \"Réglages\" -> \"Autoptimize\" et commencer à améliorer les performances de votre site"
 
 
 
 
 
 
20
 
21
+ #: autoptimize.php:123
22
+ msgid "Autoptimize has just been updated. Please <strong>test your site now</strong> and adapt Autoptimize config if needed."
23
+ msgstr "Autoptimize vient d'être mis à jour. Vous pouvez maintenant <trong>tester votre site</strong> et adapter si besoin les paramètres d'Autoptimize."
 
 
 
 
24
 
25
  #: classes/autoptimizeConfig.php:56
26
  msgid "Autoptimize Settings"
27
  msgstr "Configuration d'Autoptimize"
28
 
29
+ #: classes/autoptimizeConfig.php:62
30
+ #: classes/autoptimizeConfig.php:68
31
  msgid "Show advanced settings"
32
  msgstr "Afficher les paramètres avancés"
33
 
34
+ #: classes/autoptimizeConfig.php:63
35
+ #: classes/autoptimizeConfig.php:69
36
  msgid "Hide advanced settings"
37
  msgstr "Cacher les paramètres avancés"
38
 
49
  msgstr "Préserver les commentaires HTML"
50
 
51
  #: classes/autoptimizeConfig.php:86
52
+ msgid "Enable this if you want HTML comments to remain in the page, needed for e.g. AdSense to function properly."
53
+ msgstr "Sélectionnez cette option si vous souhaitez que vos commentaires HTML restent dans la page (nécessaire par exemple pour qu'Adsense fonctionne)"
 
 
 
 
54
 
55
  #: classes/autoptimizeConfig.php:90
56
  msgid "JavaScript Options"
65
  msgstr "Forcer le JavaScript à charger dans l'en-tête de la page ?"
66
 
67
  #: classes/autoptimizeConfig.php:99
68
+ msgid "For performance reasons it is better to include JavaScript at the bottom of HTML, but this sometimes breaks things. Especially useful for jQuery-based themes."
69
+ msgstr "Pour améliorer les performances, il est préférable d'inclure le JavaScript à la fin du code HTML, mais cela peut parfois 'casser' certaines pages (notamment pour les thèmes à base de jQuery)."
 
 
 
 
 
 
70
 
71
  #: classes/autoptimizeConfig.php:102
72
  msgid "Look for scripts only in &lt;head&gt;?"
73
  msgstr "Chercher les scripts uniquement dans l'en-tête ?"
74
 
75
  #: classes/autoptimizeConfig.php:104
76
+ msgid "Mostly usefull in combination with previous option when using jQuery-based templates, but might help keeping cache size under control."
77
+ msgstr "Surtout utile combiné aux précédentes options lorsque vous utilisez des templates à base de jQuery, mais peut aussi permettre de diminuer la taille du cache."
 
 
 
 
 
78
 
79
  #: classes/autoptimizeConfig.php:107
80
+ msgid "Exclude scripts from Autoptimize:"
81
  msgstr "Scripts à exclure d'Autoptimize"
82
 
83
  #: classes/autoptimizeConfig.php:109
84
+ msgid "A comma-seperated list of scripts you want to exclude from being optimized, for example 'whatever.js, another.js' (without the quotes) to exclude those scripts from being aggregated and minimized by Autoptimize."
85
+ msgstr "Liste des scripts - séparés par des virgules - que vous ne souhaitez pas Autoptimiser. Par exemple: 'monscript.js, monautrescript.js' (sans les gullemets) pour exclure ces scripts de l'aggrégation et la compression réalisée par Autoptimize."
 
 
 
 
 
 
 
86
 
87
  #: classes/autoptimizeConfig.php:112
88
  msgid "Add try-catch wrapping?"
89
  msgstr "Ajouter une gestion des erreurs (trycatch) ?"
90
 
91
  #: classes/autoptimizeConfig.php:114
92
+ msgid "If your scripts break because of an script error, you might want to try this."
93
+ msgstr "Si votre script est 'cassé' par des erreurs, vous pouvez essayer cette option."
 
 
 
94
 
95
  #: classes/autoptimizeConfig.php:118
96
  msgid "CSS Options"
105
  msgstr "Génération de données: URI pour les images?"
106
 
107
  #: classes/autoptimizeConfig.php:127
108
+ msgid "Enable this to include small background-images in the CSS itself instead of as seperate downloads."
109
+ msgstr "Sélectionnez cette option pour inclure les petites images de fond dans le CSS lui-même au lieu d'un chargement séparé."
 
 
 
 
110
 
111
  #: classes/autoptimizeConfig.php:130
112
+ msgid "Look for styles only in &lt;head&gt;?"
113
+ msgstr "Ne rechercher les styles que dans l'en-tête ?"
114
 
115
  #: classes/autoptimizeConfig.php:132
116
+ msgid "Don't autoptimize CSS outside the head-section. If the cache gets big, you might want to enable this."
117
+ msgstr "N'optimise pas les CSS situés en dehors de l'en-tête. Si votre cache devient trop important, vous pouvez utliser cette option."
 
 
 
 
 
118
 
119
  #: classes/autoptimizeConfig.php:135
120
+ msgid "Defer CSS loading?"
121
+ msgstr "Reporter le chargement des CSS"
122
 
123
  #: classes/autoptimizeConfig.php:137
124
+ msgid "Load optimized CSS only after page load (disables CSS inlining). <strong>Warning</strong>: <a href=\"http://wordpress.org/plugins/autoptimize/faq/\" target=\"_blank\">check the FAQ</a> before activating this option!"
125
+ msgstr "Ne chargez les CSS optimizées qu'après le chargement du page. <strong>Avertissement</strong>: <a href=\"http://wordpress.org/plugins/autoptimize/faq/\" target=\"_blank\">Lisez le FAQ (en Anglais)</a> avant d'activer cette option!"
 
 
 
 
126
 
127
  #: classes/autoptimizeConfig.php:140
128
+ msgid "Inline all CSS?"
129
+ msgstr "Mettez tout les CSS dans votre code HTML."
130
 
131
  #: classes/autoptimizeConfig.php:142
132
+ msgid "Inlining all CSS can improve performance for sites with a low pageviews/ visitor-rate, but may slow down performance otherwise. CSS inlining disables CSS deferring."
133
+ msgstr "Mettre les CSS dans le code HTML peut améliorer la performance moyenne si votre site atteint une ratio vue pages/ visiteurs baisse, sinon la performance moyenne être plus mauvaise."
134
+
135
+ #: classes/autoptimizeConfig.php:145
136
+ msgid "Exclude CSS from Autoptimize:"
137
+ msgstr "Exclure ces CSS d'Autoptimise."
138
+
139
+ #: classes/autoptimizeConfig.php:147
140
+ msgid "A comma-seperated list of CSS you want to exclude from being optimized."
141
+ msgstr "Liste des fichiers CSS - séparés par des virgules - que vous souhaitez exclure de l'Autoptimisation."
142
 
143
+ #: classes/autoptimizeConfig.php:151
144
  msgid "CDN Options"
145
  msgstr "Options CDN"
146
 
147
+ #: classes/autoptimizeConfig.php:154
148
  msgid "CDN Base URL"
149
  msgstr "Base URL du CDN"
150
 
151
+ #: classes/autoptimizeConfig.php:156
152
+ msgid "Enter your CDN blog root directory URL if you want to enable CDN for images referenced in the CSS."
153
+ msgstr "Saisissez l'URL du répertoire racine de votre site si vous souhaitez utiliser un CDN pour les images référencés dans le CSS."
 
 
154
 
155
+ #: classes/autoptimizeConfig.php:160
156
  msgid "Cache Info"
157
  msgstr "Informations du cache"
158
 
159
+ #: classes/autoptimizeConfig.php:163
160
  msgid "Cache folder"
161
  msgstr "Répertoire du cache"
162
 
163
+ #: classes/autoptimizeConfig.php:167
164
  msgid "Can we write?"
165
  msgstr "Droits d'écriture ?"
166
 
167
+ #: classes/autoptimizeConfig.php:168
168
  msgid "Yes"
169
  msgstr "Oui"
170
 
171
+ #: classes/autoptimizeConfig.php:168
172
  msgid "No"
173
  msgstr "Non"
174
 
175
+ #: classes/autoptimizeConfig.php:171
176
  msgid "Cached styles and scripts"
177
  msgstr "Styles et scripts en cache"
178
 
179
+ #: classes/autoptimizeConfig.php:175
180
  msgid "Save aggregated script/css as static files?"
181
  msgstr "Enregistrer les scripts/css en tant que fichiers statiques ?"
182
 
183
+ #: classes/autoptimizeConfig.php:177
184
+ msgid "By default files saved are static css/js, uncheck this option if your webserver doesn't properly handle the compression and expiry."
185
+ msgstr "Par defaut les fichiers JS/ CSS seront servi d'une manière statique. Désactivez cette option si votre serveur web ne peut pas gérer la compression et l'expiration des fichiers."
 
 
186
 
187
+ #: classes/autoptimizeConfig.php:183
188
  msgid "Save Changes"
189
  msgstr "Enregistrer les modifications"
190
 
191
+ #: classes/autoptimizeConfig.php:184
192
  msgid "Save Changes and Empty Cache"
193
  msgstr "Enregistrer les modifications et vider le cache"
194
 
195
+ #: classes/autoptimizeConfig.php:192
 
 
 
 
196
  msgid "futtta about"
197
  msgstr "futta à propos de"
198
 
199
+ #. #-#-#-#-# plugin.pot (Autoptimize 1.8.0) #-#-#-#-#
200
  #. Plugin Name of the plugin/theme
201
+ #: classes/autoptimizeConfig.php:194
202
  msgid "Autoptimize"
203
  msgstr "Autoptimize"
204
 
205
+ #: classes/autoptimizeConfig.php:195
206
  msgid "WordPress"
207
  msgstr "WordPress"
208
 
209
+ #: classes/autoptimizeConfig.php:196
210
  msgid "Web Technology"
211
  msgstr "La technologie Web"
212
 
213
+ #: classes/autoptimizeConfig.php:201
214
+ msgid "Do not donate for this plugin!"
215
+ msgstr "Ne faites pas de don pas pour ce plugin!"
216
+
217
+ #: classes/autoptimizeConfig.php:262
218
  msgid "Autoptimize Options"
219
  msgstr "Options Autoptimize "
220
 
221
+ #: classes/autoptimizeConfig.php:309
222
+ #: classes/autoptimizeConfig.php:316
223
  msgid "Settings"
224
  msgstr "Paramètres"
225
 
228
  msgstr "http://blog.futtta.be/autoptimize"
229
 
230
  #. Description of the plugin/theme
231
+ msgid "Optimizes your website, concatenating the CSS and JavaScript code, and compressing it."
232
+ msgstr "Optimise votre site web en rassemblant les CSS et JavaScript et en les compressant."
 
 
 
 
233
 
234
  #. Author of the plugin/theme
235
  msgid "Frank Goossens (futtta)"
238
  #. Author URI of the plugin/theme
239
  msgid "http://blog.futtta.be/"
240
  msgstr "http://blog.futtta.be/"
241
+
242
+ #~ msgid ""
243
+ #~ "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for "
244
+ #~ "mobile performance reasons having it deferred can be better."
245
+ #~ msgstr ""
246
+ #~ "Normalement, les CSS sont chargés dans l'en-tête du code HTML, mais pour "
247
+ #~ "améliorer les performances de lecture par un terminal mobile, il peut "
248
+ #~ "être préférable de reporter ce chargement."
localization/autoptimize-nl_BE.mo CHANGED
Binary file
localization/autoptimize-nl_BE.po CHANGED
@@ -2,10 +2,10 @@
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Autoptimize 1.7.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
- "POT-Creation-Date: 2013-10-21 07:38:13+00:00\n"
8
- "PO-Revision-Date: 2013-10-21 12:33+0100\n"
9
  "Last-Translator: frank goossens <futtta@gmail.com>\n"
10
  "Language-Team: <futtta@gmail.com>\n"
11
  "MIME-Version: 1.0\n"
@@ -14,11 +14,11 @@ msgstr ""
14
  "X-Poedit-Language: Dutch\n"
15
  "X-Poedit-Country: BELGIUM\n"
16
 
17
- #: autoptimize.php:66
18
  msgid "Thank you for installing and activating Autoptimize. Please configure it under \"Settings\" -> \"Autoptimize\" to start improving your site's performance."
19
  msgstr "Tof dat je Autoptimize geïnstalleerd hebt! Je kunt de plugin nu configureren onder \"Instellingen\" -> \"Autoptimize\"."
20
 
21
- #: autoptimize.php:72
22
  msgid "Autoptimize has just been updated. Please <strong>test your site now</strong> and adapt Autoptimize config if needed."
23
  msgstr "Autoptimize is juist geüpdate, <strong>test je site nu</strong> en wijzig de Autoptimize instellingen indien nodig."
24
 
@@ -77,11 +77,11 @@ msgid "Mostly usefull in combination with previous option when using jQuery-base
77
  msgstr "Vooral nuttig in combinatie met de vorige optie voor jQuery-gebaseerde sites, maar kan ook helpen om de cache-size onder controle te houden."
78
 
79
  #: classes/autoptimizeConfig.php:107
80
- msgid "Exclude scripts from autoptimize:"
81
  msgstr "Sluit deze scripts uit van optimalisering:"
82
 
83
  #: classes/autoptimizeConfig.php:109
84
- msgid "A comma-seperated list of scripts you want to exclude from being Autoptimized, for example 'whatever.js, another.js' (without the quotes) to exclude those scripts from being aggregated and minimized by Autoptimize."
85
  msgstr "Lijst van scripts die je wilt uitsluiten van optimalisatie, gescheiden door komma's. Voorbeeld; 'whatever.js, another.js' (zonder de quotes)."
86
 
87
  #: classes/autoptimizeConfig.php:112
@@ -109,109 +109,117 @@ msgid "Enable this to include small background-images in the CSS itself instead
109
  msgstr "Acitveer deze optie om kleine background-images in de CSS te bewaren in plaats van aparte files."
110
 
111
  #: classes/autoptimizeConfig.php:130
112
- msgid "Defer CSS loading?"
113
- msgstr "Stel inladen CSS uit tot na binnenhalen pagina?"
114
 
115
  #: classes/autoptimizeConfig.php:132
116
- msgid "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for mobile performance reasons having it deferred can be better."
117
- msgstr "Normaal wordt CSS in de &lt;head&gt;-sectie van de HTML geladen, maar voor mobiele performantie kan het beter zijn om dat pas op het einde van de HTML te doen."
118
 
119
  #: classes/autoptimizeConfig.php:135
120
- msgid "Look for styles only in &lt;head&gt;?"
121
- msgstr "Haal CSS enkel uit &lt;head&gt;?"
122
 
123
  #: classes/autoptimizeConfig.php:137
124
- msgid "Don't autoptimize CSS outside the head-section. If the cache gets big, you might want to enable this."
125
- msgstr "De CSS buiten de &lt;head&gt; niet mee optimaliseren. Kan helpen om de cache-omvang te beperken."
126
 
127
  #: classes/autoptimizeConfig.php:140
128
- msgid "Exclude CSS from autoptimize:"
129
- msgstr "Sluit deze CSS uit van optimalisering:"
130
 
131
  #: classes/autoptimizeConfig.php:142
132
- msgid "A comma-seperated list of CSS you want to exclude from being Autoptimized."
 
 
 
 
 
 
 
 
133
  msgstr "Lijst van CSS die je wilt uitsluiten van optimalisatie, gescheiden door komma's. Voorbeeld; 'whatever.css, style.css' (zonder de quotes)."
134
 
135
- #: classes/autoptimizeConfig.php:146
136
  msgid "CDN Options"
137
  msgstr "CDN Opties"
138
 
139
- #: classes/autoptimizeConfig.php:149
140
  msgid "CDN Base URL"
141
  msgstr "Basis CDN URL"
142
 
143
- #: classes/autoptimizeConfig.php:151
144
- msgid "Enter your CDN blog root directory URL if you want to enable CDN."
145
- msgstr "Vul hier je CDN blog root directory URL in om CDN te activeren."
146
 
147
- #: classes/autoptimizeConfig.php:155
148
  msgid "Cache Info"
149
  msgstr "Cache Info"
150
 
151
- #: classes/autoptimizeConfig.php:158
152
  msgid "Cache folder"
153
  msgstr "Cache folder"
154
 
155
- #: classes/autoptimizeConfig.php:162
156
  msgid "Can we write?"
157
  msgstr "Kunnen we schrijven naar die folder?"
158
 
159
- #: classes/autoptimizeConfig.php:163
160
  msgid "Yes"
161
  msgstr "Ja"
162
 
163
- #: classes/autoptimizeConfig.php:163
164
  msgid "No"
165
  msgstr "Nee"
166
 
167
- #: classes/autoptimizeConfig.php:166
168
  msgid "Cached styles and scripts"
169
  msgstr "CSS en scripts in cache"
170
 
171
- #: classes/autoptimizeConfig.php:170
172
  msgid "Save aggregated script/css as static files?"
173
  msgstr "Bewaar geoptimaliseerde CSS en JS als statische bestanden?"
174
 
175
- #: classes/autoptimizeConfig.php:172
176
- msgid "Enable this if your webserver can handle the compression and expiry."
177
- msgstr "Activeer dit als je webserver compressie en cache-baarheid zelf kan afhandelen."
178
 
179
- #: classes/autoptimizeConfig.php:178
180
  msgid "Save Changes"
181
  msgstr "Bewaar wijzigingen"
182
 
183
- #: classes/autoptimizeConfig.php:179
184
  msgid "Save Changes and Empty Cache"
185
  msgstr "Bewaar en maak cache leeg."
186
 
187
- #: classes/autoptimizeConfig.php:185
188
- msgid "Do not donate for this plugin!"
189
- msgstr "Geef geen geld voor deze plugin!"
190
-
191
- #: classes/autoptimizeConfig.php:188
192
  msgid "futtta about"
193
  msgstr "futtta over"
194
 
195
- #. #-#-#-#-# plugin.pot (Autoptimize 1.7.0) #-#-#-#-#
196
  #. Plugin Name of the plugin/theme
197
- #: classes/autoptimizeConfig.php:190
198
  msgid "Autoptimize"
199
  msgstr "Autoptimize"
200
 
201
- #: classes/autoptimizeConfig.php:191
202
  msgid "WordPress"
203
  msgstr "WordPress"
204
 
205
- #: classes/autoptimizeConfig.php:192
206
  msgid "Web Technology"
207
  msgstr "Web Technologie"
208
 
209
- #: classes/autoptimizeConfig.php:245
 
 
 
 
210
  msgid "Autoptimize Options"
211
  msgstr "Autoptimize Opties"
212
 
213
- #: classes/autoptimizeConfig.php:291
214
- #: classes/autoptimizeConfig.php:298
215
  msgid "Settings"
216
  msgstr "Instellingen"
217
 
@@ -231,3 +239,10 @@ msgstr "Frank Goossens (futtta)"
231
  msgid "http://blog.futtta.be/"
232
  msgstr "http://blog.futtta.be/"
233
 
 
 
 
 
 
 
 
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Autoptimize 1.8.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
+ "POT-Creation-Date: 2014-01-17 18:16:35+00:00\n"
8
+ "PO-Revision-Date: 2014-01-22 08:18+0100\n"
9
  "Last-Translator: frank goossens <futtta@gmail.com>\n"
10
  "Language-Team: <futtta@gmail.com>\n"
11
  "MIME-Version: 1.0\n"
14
  "X-Poedit-Language: Dutch\n"
15
  "X-Poedit-Country: BELGIUM\n"
16
 
17
+ #: autoptimize.php:117
18
  msgid "Thank you for installing and activating Autoptimize. Please configure it under \"Settings\" -> \"Autoptimize\" to start improving your site's performance."
19
  msgstr "Tof dat je Autoptimize geïnstalleerd hebt! Je kunt de plugin nu configureren onder \"Instellingen\" -> \"Autoptimize\"."
20
 
21
+ #: autoptimize.php:123
22
  msgid "Autoptimize has just been updated. Please <strong>test your site now</strong> and adapt Autoptimize config if needed."
23
  msgstr "Autoptimize is juist geüpdate, <strong>test je site nu</strong> en wijzig de Autoptimize instellingen indien nodig."
24
 
77
  msgstr "Vooral nuttig in combinatie met de vorige optie voor jQuery-gebaseerde sites, maar kan ook helpen om de cache-size onder controle te houden."
78
 
79
  #: classes/autoptimizeConfig.php:107
80
+ msgid "Exclude scripts from Autoptimize:"
81
  msgstr "Sluit deze scripts uit van optimalisering:"
82
 
83
  #: classes/autoptimizeConfig.php:109
84
+ msgid "A comma-seperated list of scripts you want to exclude from being optimized, for example 'whatever.js, another.js' (without the quotes) to exclude those scripts from being aggregated and minimized by Autoptimize."
85
  msgstr "Lijst van scripts die je wilt uitsluiten van optimalisatie, gescheiden door komma's. Voorbeeld; 'whatever.js, another.js' (zonder de quotes)."
86
 
87
  #: classes/autoptimizeConfig.php:112
109
  msgstr "Acitveer deze optie om kleine background-images in de CSS te bewaren in plaats van aparte files."
110
 
111
  #: classes/autoptimizeConfig.php:130
112
+ msgid "Look for styles only in &lt;head&gt;?"
113
+ msgstr "Haal CSS enkel uit &lt;head&gt;?"
114
 
115
  #: classes/autoptimizeConfig.php:132
116
+ msgid "Don't autoptimize CSS outside the head-section. If the cache gets big, you might want to enable this."
117
+ msgstr "De CSS buiten de &lt;head&gt; niet mee optimaliseren. Kan helpen om de cache-omvang te beperken."
118
 
119
  #: classes/autoptimizeConfig.php:135
120
+ msgid "Defer CSS loading?"
121
+ msgstr "Stel inladen CSS uit tot na binnenhalen pagina?"
122
 
123
  #: classes/autoptimizeConfig.php:137
124
+ msgid "Load optimized CSS only after page load (disables CSS inlining). <strong>Warning</strong>: <a href=\"http://wordpress.org/plugins/autoptimize/faq/\" target=\"_blank\">check the FAQ</a> before activating this option!"
125
+ msgstr "Laad geoptimaliseerde CSS pas op na de volledige pagina (kan niet gecombineerd worden met \"CSS rechtstreeks in HTML\" laden)."
126
 
127
  #: classes/autoptimizeConfig.php:140
128
+ msgid "Inline all CSS?"
129
+ msgstr "Alle CSS rechtstreeks in HTML laden?"
130
 
131
  #: classes/autoptimizeConfig.php:142
132
+ msgid "Inlining all CSS can improve performance for sites with a low pageviews/ visitor-rate, but may slow down performance otherwise. CSS inlining disables CSS deferring."
133
+ msgstr "CSS rechtstreeks in de HTML laden kan de gemiddelde performantie voor sites met een lage pageview/ bezoeker-ratio verbeteren, maar zal in andere gevallen de performantie verslechteren. Dit kan niet gecombineerd worden met \"CSS laden uitstellen\"."
134
+
135
+ #: classes/autoptimizeConfig.php:145
136
+ msgid "Exclude CSS from Autoptimize:"
137
+ msgstr "Sluit deze CSS uit van optimalisering:"
138
+
139
+ #: classes/autoptimizeConfig.php:147
140
+ msgid "A comma-seperated list of CSS you want to exclude from being optimized."
141
  msgstr "Lijst van CSS die je wilt uitsluiten van optimalisatie, gescheiden door komma's. Voorbeeld; 'whatever.css, style.css' (zonder de quotes)."
142
 
143
+ #: classes/autoptimizeConfig.php:151
144
  msgid "CDN Options"
145
  msgstr "CDN Opties"
146
 
147
+ #: classes/autoptimizeConfig.php:154
148
  msgid "CDN Base URL"
149
  msgstr "Basis CDN URL"
150
 
151
+ #: classes/autoptimizeConfig.php:156
152
+ msgid "Enter your CDN blog root directory URL if you want to enable CDN for images referenced in the CSS."
153
+ msgstr "Vul hier je CDN blog root directory URL in om afbeeldingen in je CSS via je CDN te laden."
154
 
155
+ #: classes/autoptimizeConfig.php:160
156
  msgid "Cache Info"
157
  msgstr "Cache Info"
158
 
159
+ #: classes/autoptimizeConfig.php:163
160
  msgid "Cache folder"
161
  msgstr "Cache folder"
162
 
163
+ #: classes/autoptimizeConfig.php:167
164
  msgid "Can we write?"
165
  msgstr "Kunnen we schrijven naar die folder?"
166
 
167
+ #: classes/autoptimizeConfig.php:168
168
  msgid "Yes"
169
  msgstr "Ja"
170
 
171
+ #: classes/autoptimizeConfig.php:168
172
  msgid "No"
173
  msgstr "Nee"
174
 
175
+ #: classes/autoptimizeConfig.php:171
176
  msgid "Cached styles and scripts"
177
  msgstr "CSS en scripts in cache"
178
 
179
+ #: classes/autoptimizeConfig.php:175
180
  msgid "Save aggregated script/css as static files?"
181
  msgstr "Bewaar geoptimaliseerde CSS en JS als statische bestanden?"
182
 
183
+ #: classes/autoptimizeConfig.php:177
184
+ msgid "By default files saved are static css/js, uncheck this option if your webserver doesn't properly handle the compression and expiry."
185
+ msgstr "Standaard worden bestanden als statische css/js bewaard, deactiveer deze optie als je webserver compressie en cache-baarheid niet zelf kan afhandelen."
186
 
187
+ #: classes/autoptimizeConfig.php:183
188
  msgid "Save Changes"
189
  msgstr "Bewaar wijzigingen"
190
 
191
+ #: classes/autoptimizeConfig.php:184
192
  msgid "Save Changes and Empty Cache"
193
  msgstr "Bewaar en maak cache leeg."
194
 
195
+ #: classes/autoptimizeConfig.php:192
 
 
 
 
196
  msgid "futtta about"
197
  msgstr "futtta over"
198
 
199
+ #. #-#-#-#-# plugin.pot (Autoptimize 1.8.0) #-#-#-#-#
200
  #. Plugin Name of the plugin/theme
201
+ #: classes/autoptimizeConfig.php:194
202
  msgid "Autoptimize"
203
  msgstr "Autoptimize"
204
 
205
+ #: classes/autoptimizeConfig.php:195
206
  msgid "WordPress"
207
  msgstr "WordPress"
208
 
209
+ #: classes/autoptimizeConfig.php:196
210
  msgid "Web Technology"
211
  msgstr "Web Technologie"
212
 
213
+ #: classes/autoptimizeConfig.php:201
214
+ msgid "Do not donate for this plugin!"
215
+ msgstr "Geef geen geld voor deze plugin!"
216
+
217
+ #: classes/autoptimizeConfig.php:262
218
  msgid "Autoptimize Options"
219
  msgstr "Autoptimize Opties"
220
 
221
+ #: classes/autoptimizeConfig.php:309
222
+ #: classes/autoptimizeConfig.php:316
223
  msgid "Settings"
224
  msgstr "Instellingen"
225
 
239
  msgid "http://blog.futtta.be/"
240
  msgstr "http://blog.futtta.be/"
241
 
242
+ #~ msgid ""
243
+ #~ "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for "
244
+ #~ "mobile performance reasons having it deferred can be better."
245
+ #~ msgstr ""
246
+ #~ "Normaal wordt CSS in de &lt;head&gt;-sectie van de HTML geladen, maar "
247
+ #~ "voor mobiele performantie kan het beter zijn om dat pas op het einde van "
248
+ #~ "de HTML te doen."
localization/autoptimize-nl_NL.mo CHANGED
Binary file
localization/autoptimize-nl_NL.po CHANGED
@@ -2,10 +2,10 @@
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Autoptimize 1.7.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
- "POT-Creation-Date: 2013-10-21 07:38:13+00:00\n"
8
- "PO-Revision-Date: 2013-10-21 12:29+0100\n"
9
  "Last-Translator: frank goossens <futtta@gmail.com>\n"
10
  "Language-Team: <futtta@gmail.com>\n"
11
  "MIME-Version: 1.0\n"
@@ -14,11 +14,11 @@ msgstr ""
14
  "X-Poedit-Language: Dutch\n"
15
  "X-Poedit-Country: NETHERLANDS\n"
16
 
17
- #: autoptimize.php:66
18
  msgid "Thank you for installing and activating Autoptimize. Please configure it under \"Settings\" -> \"Autoptimize\" to start improving your site's performance."
19
  msgstr "Tof dat je Autoptimize geïnstalleerd hebt! Je kunt de plugin nu configureren onder \"Instellingen\" -> \"Autoptimize\"."
20
 
21
- #: autoptimize.php:72
22
  msgid "Autoptimize has just been updated. Please <strong>test your site now</strong> and adapt Autoptimize config if needed."
23
  msgstr "Autoptimize is juist geüpdate, <strong>test je site nu</strong> en wijzig de Autoptimize instellingen indien nodig."
24
 
@@ -77,11 +77,11 @@ msgid "Mostly usefull in combination with previous option when using jQuery-base
77
  msgstr "Vooral nuttig in combinatie met de vorige optie voor jQuery-gebaseerde sites, maar kan ook helpen om de cache-size onder controle te houden."
78
 
79
  #: classes/autoptimizeConfig.php:107
80
- msgid "Exclude scripts from autoptimize:"
81
  msgstr "Sluit deze scripts uit van optimalisering:"
82
 
83
  #: classes/autoptimizeConfig.php:109
84
- msgid "A comma-seperated list of scripts you want to exclude from being Autoptimized, for example 'whatever.js, another.js' (without the quotes) to exclude those scripts from being aggregated and minimized by Autoptimize."
85
  msgstr "Lijst van scripts die je wilt uitsluiten van optimalisatie, gescheiden door komma's. Voorbeeld; 'whatever.js, another.js' (zonder de quotes)."
86
 
87
  #: classes/autoptimizeConfig.php:112
@@ -109,109 +109,117 @@ msgid "Enable this to include small background-images in the CSS itself instead
109
  msgstr "Acitveer deze optie om kleine background-images in de CSS te bewaren in plaats van aparte files."
110
 
111
  #: classes/autoptimizeConfig.php:130
112
- msgid "Defer CSS loading?"
113
- msgstr "Stel inladen CSS uit tot na binnenhalen pagina?"
114
 
115
  #: classes/autoptimizeConfig.php:132
116
- msgid "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for mobile performance reasons having it deferred can be better."
117
- msgstr "Normaal wordt CSS in de &lt;head&gt;-sectie van de HTML geladen, maar voor mobiele performantie kan het beter zijn om dat pas op het einde van de HTML te doen."
118
 
119
  #: classes/autoptimizeConfig.php:135
120
- msgid "Look for styles only in &lt;head&gt;?"
121
- msgstr "Haal CSS enkel uit &lt;head&gt;?"
122
 
123
  #: classes/autoptimizeConfig.php:137
124
- msgid "Don't autoptimize CSS outside the head-section. If the cache gets big, you might want to enable this."
125
- msgstr "De CSS buiten de &lt;head&gt; niet mee optimaliseren. Kan helpen om de cache-omvang te beperken."
126
 
127
  #: classes/autoptimizeConfig.php:140
128
- msgid "Exclude CSS from autoptimize:"
129
- msgstr "Sluit deze CSS uit van optimalisering:"
130
 
131
  #: classes/autoptimizeConfig.php:142
132
- msgid "A comma-seperated list of CSS you want to exclude from being Autoptimized."
 
 
 
 
 
 
 
 
133
  msgstr "Lijst van CSS die je wilt uitsluiten van optimalisatie, gescheiden door komma's. Voorbeeld; 'whatever.css, style.css' (zonder de quotes)."
134
 
135
- #: classes/autoptimizeConfig.php:146
136
  msgid "CDN Options"
137
  msgstr "CDN Opties"
138
 
139
- #: classes/autoptimizeConfig.php:149
140
  msgid "CDN Base URL"
141
  msgstr "Basis CDN URL"
142
 
143
- #: classes/autoptimizeConfig.php:151
144
- msgid "Enter your CDN blog root directory URL if you want to enable CDN."
145
- msgstr "Vul hier je CDN blog root directory URL in om CDN te activeren."
146
 
147
- #: classes/autoptimizeConfig.php:155
148
  msgid "Cache Info"
149
  msgstr "Cache Info"
150
 
151
- #: classes/autoptimizeConfig.php:158
152
  msgid "Cache folder"
153
  msgstr "Cache folder"
154
 
155
- #: classes/autoptimizeConfig.php:162
156
  msgid "Can we write?"
157
  msgstr "Kunnen we schrijven naar die folder?"
158
 
159
- #: classes/autoptimizeConfig.php:163
160
  msgid "Yes"
161
  msgstr "Ja"
162
 
163
- #: classes/autoptimizeConfig.php:163
164
  msgid "No"
165
  msgstr "Nee"
166
 
167
- #: classes/autoptimizeConfig.php:166
168
  msgid "Cached styles and scripts"
169
  msgstr "CSS en scripts in cache"
170
 
171
- #: classes/autoptimizeConfig.php:170
172
  msgid "Save aggregated script/css as static files?"
173
  msgstr "Bewaar geoptimaliseerde CSS en JS als statische bestanden?"
174
 
175
- #: classes/autoptimizeConfig.php:172
176
- msgid "Enable this if your webserver can handle the compression and expiry."
177
- msgstr "Activeer dit als je webserver compressie en cache-baarheid zelf kan afhandelen."
178
 
179
- #: classes/autoptimizeConfig.php:178
180
  msgid "Save Changes"
181
  msgstr "Bewaar wijzigingen"
182
 
183
- #: classes/autoptimizeConfig.php:179
184
  msgid "Save Changes and Empty Cache"
185
  msgstr "Bewaar en maak cache leeg."
186
 
187
- #: classes/autoptimizeConfig.php:185
188
- msgid "Do not donate for this plugin!"
189
- msgstr "Geef geen geld voor deze plugin!"
190
-
191
- #: classes/autoptimizeConfig.php:188
192
  msgid "futtta about"
193
  msgstr "futtta over"
194
 
195
- #. #-#-#-#-# plugin.pot (Autoptimize 1.7.0) #-#-#-#-#
196
  #. Plugin Name of the plugin/theme
197
- #: classes/autoptimizeConfig.php:190
198
  msgid "Autoptimize"
199
  msgstr "Autoptimize"
200
 
201
- #: classes/autoptimizeConfig.php:191
202
  msgid "WordPress"
203
  msgstr "WordPress"
204
 
205
- #: classes/autoptimizeConfig.php:192
206
  msgid "Web Technology"
207
  msgstr "Web Technologie"
208
 
209
- #: classes/autoptimizeConfig.php:245
 
 
 
 
210
  msgid "Autoptimize Options"
211
  msgstr "Autoptimize Opties"
212
 
213
- #: classes/autoptimizeConfig.php:291
214
- #: classes/autoptimizeConfig.php:298
215
  msgid "Settings"
216
  msgstr "Instellingen"
217
 
@@ -231,3 +239,10 @@ msgstr "Frank Goossens (futtta)"
231
  msgid "http://blog.futtta.be/"
232
  msgstr "http://blog.futtta.be/"
233
 
 
 
 
 
 
 
 
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Autoptimize 1.8.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
+ "POT-Creation-Date: 2014-01-17 18:16:35+00:00\n"
8
+ "PO-Revision-Date: 2014-01-22 08:18+0100\n"
9
  "Last-Translator: frank goossens <futtta@gmail.com>\n"
10
  "Language-Team: <futtta@gmail.com>\n"
11
  "MIME-Version: 1.0\n"
14
  "X-Poedit-Language: Dutch\n"
15
  "X-Poedit-Country: NETHERLANDS\n"
16
 
17
+ #: autoptimize.php:117
18
  msgid "Thank you for installing and activating Autoptimize. Please configure it under \"Settings\" -> \"Autoptimize\" to start improving your site's performance."
19
  msgstr "Tof dat je Autoptimize geïnstalleerd hebt! Je kunt de plugin nu configureren onder \"Instellingen\" -> \"Autoptimize\"."
20
 
21
+ #: autoptimize.php:123
22
  msgid "Autoptimize has just been updated. Please <strong>test your site now</strong> and adapt Autoptimize config if needed."
23
  msgstr "Autoptimize is juist geüpdate, <strong>test je site nu</strong> en wijzig de Autoptimize instellingen indien nodig."
24
 
77
  msgstr "Vooral nuttig in combinatie met de vorige optie voor jQuery-gebaseerde sites, maar kan ook helpen om de cache-size onder controle te houden."
78
 
79
  #: classes/autoptimizeConfig.php:107
80
+ msgid "Exclude scripts from Autoptimize:"
81
  msgstr "Sluit deze scripts uit van optimalisering:"
82
 
83
  #: classes/autoptimizeConfig.php:109
84
+ msgid "A comma-seperated list of scripts you want to exclude from being optimized, for example 'whatever.js, another.js' (without the quotes) to exclude those scripts from being aggregated and minimized by Autoptimize."
85
  msgstr "Lijst van scripts die je wilt uitsluiten van optimalisatie, gescheiden door komma's. Voorbeeld; 'whatever.js, another.js' (zonder de quotes)."
86
 
87
  #: classes/autoptimizeConfig.php:112
109
  msgstr "Acitveer deze optie om kleine background-images in de CSS te bewaren in plaats van aparte files."
110
 
111
  #: classes/autoptimizeConfig.php:130
112
+ msgid "Look for styles only in &lt;head&gt;?"
113
+ msgstr "Haal CSS enkel uit &lt;head&gt;?"
114
 
115
  #: classes/autoptimizeConfig.php:132
116
+ msgid "Don't autoptimize CSS outside the head-section. If the cache gets big, you might want to enable this."
117
+ msgstr "De CSS buiten de &lt;head&gt; niet mee optimaliseren. Kan helpen om de cache-omvang te beperken."
118
 
119
  #: classes/autoptimizeConfig.php:135
120
+ msgid "Defer CSS loading?"
121
+ msgstr "Stel inladen CSS uit tot na binnenhalen pagina?"
122
 
123
  #: classes/autoptimizeConfig.php:137
124
+ msgid "Load optimized CSS only after page load (disables CSS inlining). <strong>Warning</strong>: <a href=\"http://wordpress.org/plugins/autoptimize/faq/\" target=\"_blank\">check the FAQ</a> before activating this option!"
125
+ msgstr "Laad geoptimaliseerde CSS pas op na de volledige pagina (kan niet gecombineerd worden met \"CSS rechtstreeks in HTML\" laden)."
126
 
127
  #: classes/autoptimizeConfig.php:140
128
+ msgid "Inline all CSS?"
129
+ msgstr "Alle CSS rechtstreeks in HTML laden?"
130
 
131
  #: classes/autoptimizeConfig.php:142
132
+ msgid "Inlining all CSS can improve performance for sites with a low pageviews/ visitor-rate, but may slow down performance otherwise. CSS inlining disables CSS deferring."
133
+ msgstr "CSS rechtstreeks in de HTML laden kan de gemiddelde performantie voor sites met een lage pageview/ bezoeker-ratio verbeteren, maar zal in andere gevallen de performantie verslechteren. Dit kan niet gecombineerd worden met \"CSS laden uitstellen\"."
134
+
135
+ #: classes/autoptimizeConfig.php:145
136
+ msgid "Exclude CSS from Autoptimize:"
137
+ msgstr "Sluit deze CSS uit van optimalisering:"
138
+
139
+ #: classes/autoptimizeConfig.php:147
140
+ msgid "A comma-seperated list of CSS you want to exclude from being optimized."
141
  msgstr "Lijst van CSS die je wilt uitsluiten van optimalisatie, gescheiden door komma's. Voorbeeld; 'whatever.css, style.css' (zonder de quotes)."
142
 
143
+ #: classes/autoptimizeConfig.php:151
144
  msgid "CDN Options"
145
  msgstr "CDN Opties"
146
 
147
+ #: classes/autoptimizeConfig.php:154
148
  msgid "CDN Base URL"
149
  msgstr "Basis CDN URL"
150
 
151
+ #: classes/autoptimizeConfig.php:156
152
+ msgid "Enter your CDN blog root directory URL if you want to enable CDN for images referenced in the CSS."
153
+ msgstr "Vul hier je CDN blog root directory URL in om afbeeldingen in je CSS via je CDN te laden."
154
 
155
+ #: classes/autoptimizeConfig.php:160
156
  msgid "Cache Info"
157
  msgstr "Cache Info"
158
 
159
+ #: classes/autoptimizeConfig.php:163
160
  msgid "Cache folder"
161
  msgstr "Cache folder"
162
 
163
+ #: classes/autoptimizeConfig.php:167
164
  msgid "Can we write?"
165
  msgstr "Kunnen we schrijven naar die folder?"
166
 
167
+ #: classes/autoptimizeConfig.php:168
168
  msgid "Yes"
169
  msgstr "Ja"
170
 
171
+ #: classes/autoptimizeConfig.php:168
172
  msgid "No"
173
  msgstr "Nee"
174
 
175
+ #: classes/autoptimizeConfig.php:171
176
  msgid "Cached styles and scripts"
177
  msgstr "CSS en scripts in cache"
178
 
179
+ #: classes/autoptimizeConfig.php:175
180
  msgid "Save aggregated script/css as static files?"
181
  msgstr "Bewaar geoptimaliseerde CSS en JS als statische bestanden?"
182
 
183
+ #: classes/autoptimizeConfig.php:177
184
+ msgid "By default files saved are static css/js, uncheck this option if your webserver doesn't properly handle the compression and expiry."
185
+ msgstr "Standaard worden bestanden als statische css/js bewaard, deactiveer deze optie als je webserver compressie en cache-baarheid niet zelf kan afhandelen."
186
 
187
+ #: classes/autoptimizeConfig.php:183
188
  msgid "Save Changes"
189
  msgstr "Bewaar wijzigingen"
190
 
191
+ #: classes/autoptimizeConfig.php:184
192
  msgid "Save Changes and Empty Cache"
193
  msgstr "Bewaar en maak cache leeg."
194
 
195
+ #: classes/autoptimizeConfig.php:192
 
 
 
 
196
  msgid "futtta about"
197
  msgstr "futtta over"
198
 
199
+ #. #-#-#-#-# plugin.pot (Autoptimize 1.8.0) #-#-#-#-#
200
  #. Plugin Name of the plugin/theme
201
+ #: classes/autoptimizeConfig.php:194
202
  msgid "Autoptimize"
203
  msgstr "Autoptimize"
204
 
205
+ #: classes/autoptimizeConfig.php:195
206
  msgid "WordPress"
207
  msgstr "WordPress"
208
 
209
+ #: classes/autoptimizeConfig.php:196
210
  msgid "Web Technology"
211
  msgstr "Web Technologie"
212
 
213
+ #: classes/autoptimizeConfig.php:201
214
+ msgid "Do not donate for this plugin!"
215
+ msgstr "Geef geen geld voor deze plugin!"
216
+
217
+ #: classes/autoptimizeConfig.php:262
218
  msgid "Autoptimize Options"
219
  msgstr "Autoptimize Opties"
220
 
221
+ #: classes/autoptimizeConfig.php:309
222
+ #: classes/autoptimizeConfig.php:316
223
  msgid "Settings"
224
  msgstr "Instellingen"
225
 
239
  msgid "http://blog.futtta.be/"
240
  msgstr "http://blog.futtta.be/"
241
 
242
+ #~ msgid ""
243
+ #~ "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for "
244
+ #~ "mobile performance reasons having it deferred can be better."
245
+ #~ msgstr ""
246
+ #~ "Normaal wordt CSS in de &lt;head&gt;-sectie van de HTML geladen, maar "
247
+ #~ "voor mobiele performantie kan het beter zijn om dat pas op het einde van "
248
+ #~ "de HTML te doen."
localization/autoptimize-pl_PL.mo ADDED
Binary file
localization/autoptimize-pl_PL.po ADDED
@@ -0,0 +1,314 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Copyright (C) 2013 Autoptimize
2
+ # This file is distributed under the same license as the Autoptimize package.
3
+ msgid ""
4
+ msgstr ""
5
+ "Project-Id-Version: Autoptimize 1.7.0\n"
6
+ "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
+ "POT-Creation-Date: 2014-01-17 18:16:35+00:00\n"
8
+ "PO-Revision-Date: 2014-01-19 10:00+0100\n"
9
+ "Last-Translator: Jakub Sierpiński <jakub.sierpinski@lostar.eu>\n"
10
+ "Language-Team: LANGUAGE <LL@li.org>\n"
11
+ "Language: pl_PL\n"
12
+ "MIME-Version: 1.0\n"
13
+ "Content-Type: text/plain; charset=UTF-8\n"
14
+ "Content-Transfer-Encoding: 8bit\n"
15
+ "X-Generator: Poedit 1.6.3\n"
16
+ "Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 "
17
+ "|| n%100>=20) ? 1 : 2);\n"
18
+
19
+ #: autoptimize.php:117
20
+ msgid ""
21
+ "Thank you for installing and activating Autoptimize. Please configure it "
22
+ "under \"Settings\" -> \"Autoptimize\" to start improving your site's "
23
+ "performance."
24
+ msgstr ""
25
+ "Dziękujemy za zainstalowanie i aktywację Autoptimize. Proszę skonfiguruj "
26
+ "plugin w menu \"Ustawienia\" -> \"Autoptimize\" aby rozpocząć zwiększanie "
27
+ "wydajności Twojej witryny."
28
+
29
+ #: autoptimize.php:123
30
+ msgid ""
31
+ "Autoptimize has just been updated. Please <strong>test your site now</"
32
+ "strong> and adapt Autoptimize config if needed."
33
+ msgstr ""
34
+ "Autoptimize został właśnie uaktualniony. Prosimy o <strong>przetestowanie "
35
+ "Twojej witryny</strong> i zmienienie ustawień Autoptimize jeżeli to "
36
+ "konieczne. "
37
+
38
+ #: classes/autoptimizeConfig.php:56
39
+ msgid "Autoptimize Settings"
40
+ msgstr "Ustawienia Autoptimize"
41
+
42
+ #: classes/autoptimizeConfig.php:62 classes/autoptimizeConfig.php:68
43
+ msgid "Show advanced settings"
44
+ msgstr "Pokaż ustawienia zaawansowane"
45
+
46
+ #: classes/autoptimizeConfig.php:63 classes/autoptimizeConfig.php:69
47
+ msgid "Hide advanced settings"
48
+ msgstr "Ukryj ustawienia zaawansowane"
49
+
50
+ #: classes/autoptimizeConfig.php:77
51
+ msgid "HTML Options"
52
+ msgstr "Opcje HTML"
53
+
54
+ #: classes/autoptimizeConfig.php:80
55
+ msgid "Optimize HTML Code?"
56
+ msgstr "Optymalizuj kod HTML?"
57
+
58
+ #: classes/autoptimizeConfig.php:84
59
+ msgid "Keep HTML comments?"
60
+ msgstr "Zachowaj komentarze HTML?"
61
+
62
+ #: classes/autoptimizeConfig.php:86
63
+ msgid ""
64
+ "Enable this if you want HTML comments to remain in the page, needed for e.g. "
65
+ "AdSense to function properly."
66
+ msgstr ""
67
+ "Wybierz tą opcję jeżeli chcesz zachować komentarze HTML na stronie. Jest to "
68
+ "potrzebne n.p. do prawidłowego działania AdSense."
69
+
70
+ #: classes/autoptimizeConfig.php:90
71
+ msgid "JavaScript Options"
72
+ msgstr "Opcje Javascript"
73
+
74
+ #: classes/autoptimizeConfig.php:93
75
+ msgid "Optimize JavaScript Code?"
76
+ msgstr "Optymalizuj kod JavaScript?"
77
+
78
+ #: classes/autoptimizeConfig.php:97
79
+ msgid "Force JavaScript in &lt;head&gt;?"
80
+ msgstr "Wymuś JavaScript w &lt;head&gt;?"
81
+
82
+ #: classes/autoptimizeConfig.php:99
83
+ msgid ""
84
+ "For performance reasons it is better to include JavaScript at the bottom of "
85
+ "HTML, but this sometimes breaks things. Especially useful for jQuery-based "
86
+ "themes."
87
+ msgstr ""
88
+ "Z powodów wydajności lepiej jest umieścić JavaSkrypt na końcu HTML, ale "
89
+ "czasami to nie działa prawidłowo. Przydatne zwłaszcza w przypadku szablonów "
90
+ "opartych na jQuery."
91
+
92
+ #: classes/autoptimizeConfig.php:102
93
+ msgid "Look for scripts only in &lt;head&gt;?"
94
+ msgstr "Wyszukuj skryptów tylko w &lt;head&gt;?"
95
+
96
+ #: classes/autoptimizeConfig.php:104
97
+ msgid ""
98
+ "Mostly usefull in combination with previous option when using jQuery-based "
99
+ "templates, but might help keeping cache size under control."
100
+ msgstr ""
101
+ "Przeważnie użyteczne w połączeniu z poprzednią opcją w momencie kiedy "
102
+ "używasz szablonów opartch na jQuery, ale może również pomóc utrzymać rozmiar "
103
+ "pamięci podręcznej w ryzach."
104
+
105
+ #: classes/autoptimizeConfig.php:107
106
+ msgid "Exclude scripts from Autoptimize:"
107
+ msgstr "Skrypty wyłączone z Autoptimize:"
108
+
109
+ #: classes/autoptimizeConfig.php:109
110
+ msgid ""
111
+ "A comma-seperated list of scripts you want to exclude from being optimized, "
112
+ "for example 'whatever.js, another.js' (without the quotes) to exclude those "
113
+ "scripts from being aggregated and minimized by Autoptimize."
114
+ msgstr ""
115
+ "Rozdzielona przecinkami lista skryptów, które chcesz wyłączyć z optymizacji. "
116
+ "Na przykład \"whatever.js, another.js\" (bez cudzysłowów) wyłączy te skrypty "
117
+ "z łączenia i zmniejszania przez Autoptimize."
118
+
119
+ #: classes/autoptimizeConfig.php:112
120
+ msgid "Add try-catch wrapping?"
121
+ msgstr "Opakować skrypt w try-catch?"
122
+
123
+ #: classes/autoptimizeConfig.php:114
124
+ msgid ""
125
+ "If your scripts break because of an script error, you might want to try this."
126
+ msgstr ""
127
+ "Jeżeli Twój skrypt przestanie działać z powodu błedu skryptu możesz chcieć "
128
+ "to właczyć."
129
+
130
+ #: classes/autoptimizeConfig.php:118
131
+ msgid "CSS Options"
132
+ msgstr "Opcje CSS"
133
+
134
+ #: classes/autoptimizeConfig.php:121
135
+ msgid "Optimize CSS Code?"
136
+ msgstr "Optymalizuj kod CSS?"
137
+
138
+ #: classes/autoptimizeConfig.php:125
139
+ msgid "Generate data: URIs for images?"
140
+ msgstr "Twórz URI data: dla obrazów?"
141
+
142
+ #: classes/autoptimizeConfig.php:127
143
+ msgid ""
144
+ "Enable this to include small background-images in the CSS itself instead of "
145
+ "as seperate downloads."
146
+ msgstr ""
147
+ "Włącz to, aby zawrzeć małe obrazki tła w samym pliku CSS zamiast jako osobne "
148
+ "pliki."
149
+
150
+ #: classes/autoptimizeConfig.php:130
151
+ msgid "Look for styles only in &lt;head&gt;?"
152
+ msgstr "Wyszukuj styli tylko w &lt;head&gt;?"
153
+
154
+ #: classes/autoptimizeConfig.php:132
155
+ msgid ""
156
+ "Don't autoptimize CSS outside the head-section. If the cache gets big, you "
157
+ "might want to enable this."
158
+ msgstr ""
159
+ "Nie autoptimizuj CSS poza sekcją head. Jeżeli pamięć podręczna zrobi się za "
160
+ "duża, możesz chcieć to włączyć."
161
+
162
+ #: classes/autoptimizeConfig.php:135
163
+ msgid "Defer CSS loading?"
164
+ msgstr "Opóźnij ładowanie CSS?"
165
+
166
+ #: classes/autoptimizeConfig.php:137
167
+ msgid ""
168
+ "Load optimized CSS only after page load (disables CSS inlining). "
169
+ "<strong>Warning</strong>: <a href=\"http://wordpress.org/plugins/autoptimize/"
170
+ "faq/\" target=\"_blank\">check the FAQ</a> before activating this option!"
171
+ msgstr ""
172
+ "Wczytaj zoptymizowany CSS tylko po załadowaniu strony (wyłącza włączanie CSS "
173
+ "do strony). <strong>Uwaga</strong>: <a href=\"http://wordpress.org/plugins/"
174
+ "autoptimize/faq/\" target=\"_blank\">Sprawdź FAQ</a> przed aktywacją tej "
175
+ "opcji!"
176
+
177
+ #: classes/autoptimizeConfig.php:140
178
+ msgid "Inline all CSS?"
179
+ msgstr "Włącz cały CSS w treść strony?"
180
+
181
+ #: classes/autoptimizeConfig.php:142
182
+ msgid ""
183
+ "Inlining all CSS can improve performance for sites with a low pageviews/ "
184
+ "visitor-rate, but may slow down performance otherwise. CSS inlining disables "
185
+ "CSS deferring."
186
+ msgstr ""
187
+ "Włączenie całego CSS do strony może zwiększyć wydajność dla stron z małym "
188
+ "stosunkiem odwiedzanych stron przez gości, ale może zmniejszyć wydajność w "
189
+ "przeciwnym wypadku. Włączenie CSS do strony wyłącza opóźnianie ładowania CSS."
190
+
191
+ #: classes/autoptimizeConfig.php:145
192
+ msgid "Exclude CSS from Autoptimize:"
193
+ msgstr "Wyłącz CSS z Autoptimize:"
194
+
195
+ #: classes/autoptimizeConfig.php:147
196
+ msgid "A comma-seperated list of CSS you want to exclude from being optimized."
197
+ msgstr ""
198
+ "Rozdzielana przecinkami lista plików CSS, którechcesz wyłączyć z optymizacji."
199
+
200
+ #: classes/autoptimizeConfig.php:151
201
+ msgid "CDN Options"
202
+ msgstr "Opcje CDN"
203
+
204
+ #: classes/autoptimizeConfig.php:154
205
+ msgid "CDN Base URL"
206
+ msgstr "Bazowy URL CDN"
207
+
208
+ #: classes/autoptimizeConfig.php:156
209
+ msgid ""
210
+ "Enter your CDN blog root directory URL if you want to enable CDN for images "
211
+ "referenced in the CSS."
212
+ msgstr ""
213
+ "Wprowadź CDN-owy URL katalogu głównego Twojego bloga jeżeli chcesz włączyć "
214
+ "użycie CDN dla obrazów, do których odwołują się pliki CSS."
215
+
216
+ #: classes/autoptimizeConfig.php:160
217
+ msgid "Cache Info"
218
+ msgstr "Informacje Pamięci Podręcznej"
219
+
220
+ #: classes/autoptimizeConfig.php:163
221
+ msgid "Cache folder"
222
+ msgstr "Folder pamięci podręcznej"
223
+
224
+ #: classes/autoptimizeConfig.php:167
225
+ msgid "Can we write?"
226
+ msgstr "Czy możemy zapisywać?"
227
+
228
+ #: classes/autoptimizeConfig.php:168
229
+ msgid "Yes"
230
+ msgstr "Tak"
231
+
232
+ #: classes/autoptimizeConfig.php:168
233
+ msgid "No"
234
+ msgstr "Nie"
235
+
236
+ #: classes/autoptimizeConfig.php:171
237
+ msgid "Cached styles and scripts"
238
+ msgstr "Zbuforowane style i skrypty"
239
+
240
+ #: classes/autoptimizeConfig.php:175
241
+ msgid "Save aggregated script/css as static files?"
242
+ msgstr "Zapisać połączony scrypt/css jako plik statyczny?"
243
+
244
+ #: classes/autoptimizeConfig.php:177
245
+ msgid ""
246
+ "By default files saved are static css/js, uncheck this option if your "
247
+ "webserver doesn't properly handle the compression and expiry."
248
+ msgstr ""
249
+ "Domyślnie pliki są zapisywane jako statyczny css/js. Odznacz tą opcję jeżeli "
250
+ "Twój serwer nie obsługuje prawidłowo kompresji lub wygaśnięcia."
251
+
252
+ #: classes/autoptimizeConfig.php:183
253
+ msgid "Save Changes"
254
+ msgstr "Zapisz Zmiany"
255
+
256
+ #: classes/autoptimizeConfig.php:184
257
+ msgid "Save Changes and Empty Cache"
258
+ msgstr "Zapisz Zmiany i Opróżnij Pamięć Podręczną"
259
+
260
+ #: classes/autoptimizeConfig.php:192
261
+ msgid "futtta about"
262
+ msgstr "o futtta"
263
+
264
+ #. Plugin Name of the plugin/theme
265
+ #: classes/autoptimizeConfig.php:194
266
+ msgid "Autoptimize"
267
+ msgstr "Autoptimize"
268
+
269
+ #: classes/autoptimizeConfig.php:195
270
+ msgid "WordPress"
271
+ msgstr "WordPress"
272
+
273
+ #: classes/autoptimizeConfig.php:196
274
+ msgid "Web Technology"
275
+ msgstr "Technologie WWW"
276
+
277
+ #: classes/autoptimizeConfig.php:201
278
+ msgid "Do not donate for this plugin!"
279
+ msgstr "Nie przesyłaj swoich datków za ten plugin!"
280
+
281
+ #: classes/autoptimizeConfig.php:262
282
+ msgid "Autoptimize Options"
283
+ msgstr "Opcje Autoptimize"
284
+
285
+ #: classes/autoptimizeConfig.php:309 classes/autoptimizeConfig.php:316
286
+ msgid "Settings"
287
+ msgstr "Ustawienia"
288
+
289
+ #. Plugin URI of the plugin/theme
290
+ msgid "http://blog.futtta.be/autoptimize"
291
+ msgstr "http://blog.futtta.be/autoptimize"
292
+
293
+ #. Description of the plugin/theme
294
+ msgid ""
295
+ "Optimizes your website, concatenating the CSS and JavaScript code, and "
296
+ "compressing it."
297
+ msgstr ""
298
+ "Optymalizuje Twoją witrynę łącząc kod CSS i JavaScript, oraz kompresując go."
299
+
300
+ #. Author of the plugin/theme
301
+ msgid "Frank Goossens (futtta)"
302
+ msgstr "Frank Goossens (futtta)"
303
+
304
+ #. Author URI of the plugin/theme
305
+ msgid "http://blog.futtta.be/"
306
+ msgstr "http://blog.futtta.be/"
307
+
308
+ #~ msgid ""
309
+ #~ "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for "
310
+ #~ "mobile performance reasons having it deferred can be better."
311
+ #~ msgstr ""
312
+ #~ "Normalnie CSS jest ładowany w sekcji &lt;head&gt; pliku HTML, ale z "
313
+ #~ "powodu wydajności na urządzeniach mobilnych opóźnienie jego wczytywania "
314
+ #~ "może być lepsze."
localization/autoptimize-sv_SE.mo CHANGED
Binary file
localization/autoptimize-sv_SE.po CHANGED
@@ -1,19 +1,21 @@
1
- # Copyright (C) 2013 Autoptimize
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Autoptimize 1.7.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
- "POT-Creation-Date: 2013-10-12 10:32:38+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
11
- "PO-Revision-Date: 2013-10-14 21:54+0100\n"
12
  "Last-Translator: Jonathan Sulo <jonathan@sulo.se>\n"
13
  "Language-Team: LANGUAGE <LL@li.org>\n"
14
- "X-Generator: Poedit 1.5.7\n"
 
 
15
 
16
- #: autoptimize.php:61
17
  msgid ""
18
  "Thank you for installing and activating Autoptimize. Please configure it "
19
  "under \"Settings\" -> \"Autoptimize\" to start improving your site's "
@@ -23,6 +25,14 @@ msgstr ""
23
  "tillägget under \"Inställningar\" -> \"Autoptimize\" för att förbättra "
24
  "prestandan på din webbplats."
25
 
 
 
 
 
 
 
 
 
26
  #: classes/autoptimizeConfig.php:56
27
  msgid "Autoptimize Settings"
28
  msgstr "Inställningar för Autoptimize"
@@ -79,7 +89,7 @@ msgstr ""
79
 
80
  #: classes/autoptimizeConfig.php:102
81
  msgid "Look for scripts only in &lt;head&gt;?"
82
- msgstr "Leta efter scripts enbart i &lt;head&gt;?"
83
 
84
  #: classes/autoptimizeConfig.php:104
85
  msgid ""
@@ -90,16 +100,16 @@ msgstr ""
90
  "teman används, men kan även reducera storleken på cachen."
91
 
92
  #: classes/autoptimizeConfig.php:107
93
- msgid "Exclude scripts from autoptimize:"
94
  msgstr "Exkludera script från Autoptimize:"
95
 
96
  #: classes/autoptimizeConfig.php:109
97
  msgid ""
98
- "A comma-seperated list of scripts you want to exclude from being "
99
- "Autoptimized, for example 'whatever.js, another.js' (without the quotes) to "
100
- "exclude those scripts from being aggregated and minimized by Autoptimize."
101
  msgstr ""
102
- "En komma-separerad lista med scripts som ska exkluderas från Autoptimize. "
103
  "Ange t ex 'whatever.js, another.js' (utan citattecken) för att inte "
104
  "sammanfoga och minimera dessa script."
105
 
@@ -110,7 +120,8 @@ msgstr "Lägg till try-catch-inbäddning?"
110
  #: classes/autoptimizeConfig.php:114
111
  msgid ""
112
  "If your scripts break because of an script error, you might want to try this."
113
- msgstr "Om script slutar fungera pga script-fel, testa då detta alternativ."
 
114
 
115
  #: classes/autoptimizeConfig.php:118
116
  msgid "CSS Options"
@@ -130,118 +141,142 @@ msgid ""
130
  "as seperate downloads."
131
  msgstr ""
132
  "Välj detta för att inkludera mindre bakgrundsbilder direkt i CSS, istället "
133
- "för separata nedladdningar."
134
 
135
  #: classes/autoptimizeConfig.php:130
136
- msgid "Defer CSS loading?"
137
- msgstr "Senarelägg inladdning av CSS?"
138
 
139
  #: classes/autoptimizeConfig.php:132
140
  msgid ""
141
- "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for "
142
- "mobile performance reasons having it deferred can be better."
143
  msgstr ""
144
- "CSS laddas vanligtvis in i &lt;head&gt;-sektionen för HTML-sidan, men för "
145
- "bättre mobil prestanda kan det vara bra att senarelägga inladdningen."
146
 
147
  #: classes/autoptimizeConfig.php:135
148
- msgid "Look for styles only in &lt;head&gt;?"
149
- msgstr "Leta efter stilmallar enbart inom &lt;head&gt;?"
150
 
151
  #: classes/autoptimizeConfig.php:137
152
  msgid ""
153
- "Don't autoptimize CSS outside the head-section. If the cache gets big, you "
154
- "might want to enable this."
 
155
  msgstr ""
156
- "Optimera inte CSS utanför head-sektionen. Om cachen blir för stor, testa då "
157
- "detta alternativ."
 
 
158
 
159
  #: classes/autoptimizeConfig.php:140
160
- msgid "Exclude CSS from autoptimize:"
161
- msgstr "Exkludera CSS från Autoptimize:"
162
 
163
  #: classes/autoptimizeConfig.php:142
164
  msgid ""
165
- "A comma-seperated list of CSS you want to exclude from being Autoptimized."
 
 
 
 
 
 
 
 
 
 
 
 
 
166
  msgstr ""
167
- "En komma-separerad lista med stilmallar som ska exkluderas från Autoptimize."
168
 
169
- #: classes/autoptimizeConfig.php:146
170
  msgid "CDN Options"
171
  msgstr "CDN-alternativ"
172
 
173
- #: classes/autoptimizeConfig.php:149
174
  msgid "CDN Base URL"
175
  msgstr "CDN bas-URL"
176
 
177
- #: classes/autoptimizeConfig.php:151
178
- msgid "Enter your CDN blog root directory URL if you want to enable CDN."
 
 
179
  msgstr "Ange rotmappen för din webbplats CDN om du vill aktivera CDN."
180
 
181
- #: classes/autoptimizeConfig.php:155
182
  msgid "Cache Info"
183
  msgstr "Cache-information"
184
 
185
- #: classes/autoptimizeConfig.php:158
186
  msgid "Cache folder"
187
  msgstr "Cache-mapp"
188
 
189
- #: classes/autoptimizeConfig.php:162
190
  msgid "Can we write?"
191
  msgstr "Kan vi skriva?"
192
 
193
- #: classes/autoptimizeConfig.php:163
194
  msgid "Yes"
195
  msgstr "Ja"
196
 
197
- #: classes/autoptimizeConfig.php:163
198
  msgid "No"
199
  msgstr "Nej"
200
 
201
- #: classes/autoptimizeConfig.php:166
202
  msgid "Cached styles and scripts"
203
- msgstr "Stilmallar och scripts i cachen"
204
 
205
- #: classes/autoptimizeConfig.php:170
206
- msgid "Do not compress cache files"
207
- msgstr "Komprimera inte cache-filer"
208
 
209
- #: classes/autoptimizeConfig.php:172
210
  msgid ""
211
- "Enable this if you want to compress the served files using your webserver."
212
- msgstr "Välj detta för att komprimera filerna som levereras av din webbserver."
 
 
 
213
 
214
- #: classes/autoptimizeConfig.php:178
215
  msgid "Save Changes"
216
- msgstr "Spara inställningar"
217
 
218
- #: classes/autoptimizeConfig.php:179
219
  msgid "Save Changes and Empty Cache"
220
- msgstr "Spara inställningar och töm cache"
221
 
222
- #: classes/autoptimizeConfig.php:187
223
  msgid "futtta about"
224
  msgstr "Om futtta"
225
 
226
- #. #-#-#-#-# plugin.pot (Autoptimize 1.7.0) #-#-#-#-#
227
  #. Plugin Name of the plugin/theme
228
- #: classes/autoptimizeConfig.php:189
229
  msgid "Autoptimize"
230
  msgstr "Autoptimize"
231
 
232
- #: classes/autoptimizeConfig.php:190
233
  msgid "WordPress"
234
  msgstr "WordPress"
235
 
236
- #: classes/autoptimizeConfig.php:191
237
  msgid "Web Technology"
238
  msgstr "Webbteknik"
239
 
240
- #: classes/autoptimizeConfig.php:244
 
 
 
 
241
  msgid "Autoptimize Options"
242
- msgstr "Alternativ för Autoptimize"
243
 
244
- #: classes/autoptimizeConfig.php:290 classes/autoptimizeConfig.php:297
245
  msgid "Settings"
246
  msgstr "Inställningar"
247
 
@@ -254,8 +289,8 @@ msgid ""
254
  "Optimizes your website, concatenating the CSS and JavaScript code, and "
255
  "compressing it."
256
  msgstr ""
257
- "Optimerar din webbplats, sammanfogar CSS och Javascript samt komprimerar "
258
- "filer."
259
 
260
  #. Author of the plugin/theme
261
  msgid "Frank Goossens (futtta)"
1
+ # Copyright (C) 2014 Autoptimize
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Autoptimize 1.8.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
+ "POT-Creation-Date: 2014-01-17 18:16:35+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
11
+ "PO-Revision-Date: 2014-01-22 20:37+0100\n"
12
  "Last-Translator: Jonathan Sulo <jonathan@sulo.se>\n"
13
  "Language-Team: LANGUAGE <LL@li.org>\n"
14
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
15
+ "Language: sv_SE\n"
16
+ "X-Generator: Poedit 1.6.3\n"
17
 
18
+ #: autoptimize.php:117
19
  msgid ""
20
  "Thank you for installing and activating Autoptimize. Please configure it "
21
  "under \"Settings\" -> \"Autoptimize\" to start improving your site's "
25
  "tillägget under \"Inställningar\" -> \"Autoptimize\" för att förbättra "
26
  "prestandan på din webbplats."
27
 
28
+ #: autoptimize.php:123
29
+ msgid ""
30
+ "Autoptimize has just been updated. Please <strong>test your site now</"
31
+ "strong> and adapt Autoptimize config if needed."
32
+ msgstr ""
33
+ "Autoptimize har precis uppdaterats. Vänligen <strong>testa din sida nu</"
34
+ "strong> och ändra inställningarna för Autoptimize vid behov. "
35
+
36
  #: classes/autoptimizeConfig.php:56
37
  msgid "Autoptimize Settings"
38
  msgstr "Inställningar för Autoptimize"
89
 
90
  #: classes/autoptimizeConfig.php:102
91
  msgid "Look for scripts only in &lt;head&gt;?"
92
+ msgstr "Leta efter script enbart i &lt;head&gt;?"
93
 
94
  #: classes/autoptimizeConfig.php:104
95
  msgid ""
100
  "teman används, men kan även reducera storleken på cachen."
101
 
102
  #: classes/autoptimizeConfig.php:107
103
+ msgid "Exclude scripts from Autoptimize:"
104
  msgstr "Exkludera script från Autoptimize:"
105
 
106
  #: classes/autoptimizeConfig.php:109
107
  msgid ""
108
+ "A comma-seperated list of scripts you want to exclude from being optimized, "
109
+ "for example 'whatever.js, another.js' (without the quotes) to exclude those "
110
+ "scripts from being aggregated and minimized by Autoptimize."
111
  msgstr ""
112
+ "En komma-separerad lista med script som ska exkluderas från Autoptimize. "
113
  "Ange t ex 'whatever.js, another.js' (utan citattecken) för att inte "
114
  "sammanfoga och minimera dessa script."
115
 
120
  #: classes/autoptimizeConfig.php:114
121
  msgid ""
122
  "If your scripts break because of an script error, you might want to try this."
123
+ msgstr ""
124
+ "Om script slutar fungera pga ett script-fel, testa då detta alternativ."
125
 
126
  #: classes/autoptimizeConfig.php:118
127
  msgid "CSS Options"
141
  "as seperate downloads."
142
  msgstr ""
143
  "Välj detta för att inkludera mindre bakgrundsbilder direkt i CSS, istället "
144
+ "för som separata nedladdningar."
145
 
146
  #: classes/autoptimizeConfig.php:130
147
+ msgid "Look for styles only in &lt;head&gt;?"
148
+ msgstr "Leta efter stilmallar enbart inom &lt;head&gt;?"
149
 
150
  #: classes/autoptimizeConfig.php:132
151
  msgid ""
152
+ "Don't autoptimize CSS outside the head-section. If the cache gets big, you "
153
+ "might want to enable this."
154
  msgstr ""
155
+ "Optimera inte CSS utanför head-sektionen. Om cachen blir för stor, testa "
156
+ "detta alternativ."
157
 
158
  #: classes/autoptimizeConfig.php:135
159
+ msgid "Defer CSS loading?"
160
+ msgstr "Senarelägg inladdning av CSS?"
161
 
162
  #: classes/autoptimizeConfig.php:137
163
  msgid ""
164
+ "Load optimized CSS only after page load (disables CSS inlining). "
165
+ "<strong>Warning</strong>: <a href=\"http://wordpress.org/plugins/autoptimize/"
166
+ "faq/\" target=\"_blank\">check the FAQ</a> before activating this option!"
167
  msgstr ""
168
+ "Ladda optimerad CSS efter att sidan har laddats (inaktiverar CSS-"
169
+ "inkludering). <strong>Varning</strong>: <a href=\"http://wordpress.org/"
170
+ "plugins/autoptimize/faq/\" target=\"_blank\">läs vanliga frågor/FAQ</a> "
171
+ "innan detta alternativ aktiveras!"
172
 
173
  #: classes/autoptimizeConfig.php:140
174
+ msgid "Inline all CSS?"
175
+ msgstr "Inkludera all CSS?"
176
 
177
  #: classes/autoptimizeConfig.php:142
178
  msgid ""
179
+ "Inlining all CSS can improve performance for sites with a low pageviews/ "
180
+ "visitor-rate, but may slow down performance otherwise. CSS inlining disables "
181
+ "CSS deferring."
182
+ msgstr ""
183
+ "Att inkludera all CSS (inline) kan förbättra prestandan på sidor med få "
184
+ "sidvisningar/besökare, men det kan även försämra prestandan. CSS-inkludering "
185
+ "inaktiverar senarelagd inladdning av CSS."
186
+
187
+ #: classes/autoptimizeConfig.php:145
188
+ msgid "Exclude CSS from Autoptimize:"
189
+ msgstr "Leta efter stilmallar enbart inom &lt;head&gt;?"
190
+
191
+ #: classes/autoptimizeConfig.php:147
192
+ msgid "A comma-seperated list of CSS you want to exclude from being optimized."
193
  msgstr ""
194
+ "En komma-separerad lista med stilmallar som ska exkluderas från optimering."
195
 
196
+ #: classes/autoptimizeConfig.php:151
197
  msgid "CDN Options"
198
  msgstr "CDN-alternativ"
199
 
200
+ #: classes/autoptimizeConfig.php:154
201
  msgid "CDN Base URL"
202
  msgstr "CDN bas-URL"
203
 
204
+ #: classes/autoptimizeConfig.php:156
205
+ msgid ""
206
+ "Enter your CDN blog root directory URL if you want to enable CDN for images "
207
+ "referenced in the CSS."
208
  msgstr "Ange rotmappen för din webbplats CDN om du vill aktivera CDN."
209
 
210
+ #: classes/autoptimizeConfig.php:160
211
  msgid "Cache Info"
212
  msgstr "Cache-information"
213
 
214
+ #: classes/autoptimizeConfig.php:163
215
  msgid "Cache folder"
216
  msgstr "Cache-mapp"
217
 
218
+ #: classes/autoptimizeConfig.php:167
219
  msgid "Can we write?"
220
  msgstr "Kan vi skriva?"
221
 
222
+ #: classes/autoptimizeConfig.php:168
223
  msgid "Yes"
224
  msgstr "Ja"
225
 
226
+ #: classes/autoptimizeConfig.php:168
227
  msgid "No"
228
  msgstr "Nej"
229
 
230
+ #: classes/autoptimizeConfig.php:171
231
  msgid "Cached styles and scripts"
232
+ msgstr "Stilmallar och script i cachen"
233
 
234
+ #: classes/autoptimizeConfig.php:175
235
+ msgid "Save aggregated script/css as static files?"
236
+ msgstr "Spara sammanfogade script/stilmallar som statiska filer?"
237
 
238
+ #: classes/autoptimizeConfig.php:177
239
  msgid ""
240
+ "By default files saved are static css/js, uncheck this option if your "
241
+ "webserver doesn't properly handle the compression and expiry."
242
+ msgstr ""
243
+ "Som standard sparas filer som statisk CSS/Javascript. Välj detta alternativ "
244
+ "om din webbserver inte kan hantera komprimering och utgångstid ordentligt."
245
 
246
+ #: classes/autoptimizeConfig.php:183
247
  msgid "Save Changes"
248
+ msgstr "Spara ändringar"
249
 
250
+ #: classes/autoptimizeConfig.php:184
251
  msgid "Save Changes and Empty Cache"
252
+ msgstr "Spara ändringar och töm cache"
253
 
254
+ #: classes/autoptimizeConfig.php:192
255
  msgid "futtta about"
256
  msgstr "Om futtta"
257
 
 
258
  #. Plugin Name of the plugin/theme
259
+ #: classes/autoptimizeConfig.php:194
260
  msgid "Autoptimize"
261
  msgstr "Autoptimize"
262
 
263
+ #: classes/autoptimizeConfig.php:195
264
  msgid "WordPress"
265
  msgstr "WordPress"
266
 
267
+ #: classes/autoptimizeConfig.php:196
268
  msgid "Web Technology"
269
  msgstr "Webbteknik"
270
 
271
+ #: classes/autoptimizeConfig.php:201
272
+ msgid "Do not donate for this plugin!"
273
+ msgstr "Donera inte för detta tillägg!"
274
+
275
+ #: classes/autoptimizeConfig.php:262
276
  msgid "Autoptimize Options"
277
+ msgstr "Autoptimize-alternativ"
278
 
279
+ #: classes/autoptimizeConfig.php:309 classes/autoptimizeConfig.php:316
280
  msgid "Settings"
281
  msgstr "Inställningar"
282
 
289
  "Optimizes your website, concatenating the CSS and JavaScript code, and "
290
  "compressing it."
291
  msgstr ""
292
+ "Optimerar din webbplats genom att sammanfoga CSS/stilmallar och Javascript "
293
+ "samt komprimerar filer."
294
 
295
  #. Author of the plugin/theme
296
  msgid "Frank Goossens (futtta)"
localization/autoptimize.pot CHANGED
@@ -1,25 +1,25 @@
1
- # Copyright (C) 2013 Autoptimize
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
- "Project-Id-Version: Autoptimize 1.7.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
- "POT-Creation-Date: 2013-10-21 07:38:13+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
11
- "PO-Revision-Date: 2013-MO-DA HO:MI+ZONE\n"
12
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
  "Language-Team: LANGUAGE <LL@li.org>\n"
14
 
15
- #: autoptimize.php:66
16
  msgid ""
17
  "Thank you for installing and activating Autoptimize. Please configure it "
18
  "under \"Settings\" -> \"Autoptimize\" to start improving your site's "
19
  "performance."
20
  msgstr ""
21
 
22
- #: autoptimize.php:72
23
  msgid ""
24
  "Autoptimize has just been updated. Please <strong>test your site now</"
25
  "strong> and adapt Autoptimize config if needed."
@@ -85,14 +85,14 @@ msgid ""
85
  msgstr ""
86
 
87
  #: classes/autoptimizeConfig.php:107
88
- msgid "Exclude scripts from autoptimize:"
89
  msgstr ""
90
 
91
  #: classes/autoptimizeConfig.php:109
92
  msgid ""
93
- "A comma-seperated list of scripts you want to exclude from being "
94
- "Autoptimized, for example 'whatever.js, another.js' (without the quotes) to "
95
- "exclude those scripts from being aggregated and minimized by Autoptimize."
96
  msgstr ""
97
 
98
  #: classes/autoptimizeConfig.php:112
@@ -123,113 +123,128 @@ msgid ""
123
  msgstr ""
124
 
125
  #: classes/autoptimizeConfig.php:130
126
- msgid "Defer CSS loading?"
127
  msgstr ""
128
 
129
  #: classes/autoptimizeConfig.php:132
130
  msgid ""
131
- "Normally CSS is loaded in the &lt;head&gt;-section of the HTML, but for "
132
- "mobile performance reasons having it deferred can be better."
133
  msgstr ""
134
 
135
  #: classes/autoptimizeConfig.php:135
136
- msgid "Look for styles only in &lt;head&gt;?"
137
  msgstr ""
138
 
139
  #: classes/autoptimizeConfig.php:137
140
  msgid ""
141
- "Don't autoptimize CSS outside the head-section. If the cache gets big, you "
142
- "might want to enable this."
 
143
  msgstr ""
144
 
145
  #: classes/autoptimizeConfig.php:140
146
- msgid "Exclude CSS from autoptimize:"
147
  msgstr ""
148
 
149
  #: classes/autoptimizeConfig.php:142
150
  msgid ""
151
- "A comma-seperated list of CSS you want to exclude from being Autoptimized."
 
 
 
 
 
 
152
  msgstr ""
153
 
154
- #: classes/autoptimizeConfig.php:146
 
 
 
 
155
  msgid "CDN Options"
156
  msgstr ""
157
 
158
- #: classes/autoptimizeConfig.php:149
159
  msgid "CDN Base URL"
160
  msgstr ""
161
 
162
- #: classes/autoptimizeConfig.php:151
163
- msgid "Enter your CDN blog root directory URL if you want to enable CDN."
 
 
164
  msgstr ""
165
 
166
- #: classes/autoptimizeConfig.php:155
167
  msgid "Cache Info"
168
  msgstr ""
169
 
170
- #: classes/autoptimizeConfig.php:158
171
  msgid "Cache folder"
172
  msgstr ""
173
 
174
- #: classes/autoptimizeConfig.php:162
175
  msgid "Can we write?"
176
  msgstr ""
177
 
178
- #: classes/autoptimizeConfig.php:163
179
  msgid "Yes"
180
  msgstr ""
181
 
182
- #: classes/autoptimizeConfig.php:163
183
  msgid "No"
184
  msgstr ""
185
 
186
- #: classes/autoptimizeConfig.php:166
187
  msgid "Cached styles and scripts"
188
  msgstr ""
189
 
190
- #: classes/autoptimizeConfig.php:170
191
  msgid "Save aggregated script/css as static files?"
192
  msgstr ""
193
 
194
- #: classes/autoptimizeConfig.php:172
195
- msgid "Enable this if your webserver can handle the compression and expiry."
 
 
196
  msgstr ""
197
 
198
- #: classes/autoptimizeConfig.php:178
199
  msgid "Save Changes"
200
  msgstr ""
201
 
202
- #: classes/autoptimizeConfig.php:179
203
  msgid "Save Changes and Empty Cache"
204
  msgstr ""
205
 
206
- #: classes/autoptimizeConfig.php:185
207
- msgid "Do not donate for this plugin!"
208
- msgstr ""
209
-
210
- #: classes/autoptimizeConfig.php:188
211
  msgid "futtta about"
212
  msgstr ""
213
 
214
- #. #-#-#-#-# plugin.pot (Autoptimize 1.7.0) #-#-#-#-#
215
  #. Plugin Name of the plugin/theme
216
- #: classes/autoptimizeConfig.php:190
217
  msgid "Autoptimize"
218
  msgstr ""
219
 
220
- #: classes/autoptimizeConfig.php:191
221
  msgid "WordPress"
222
  msgstr ""
223
 
224
- #: classes/autoptimizeConfig.php:192
225
  msgid "Web Technology"
226
  msgstr ""
227
 
228
- #: classes/autoptimizeConfig.php:245
 
 
 
 
229
  msgid "Autoptimize Options"
230
  msgstr ""
231
 
232
- #: classes/autoptimizeConfig.php:291 classes/autoptimizeConfig.php:298
233
  msgid "Settings"
234
  msgstr ""
235
 
1
+ # Copyright (C) 2014 Autoptimize
2
  # This file is distributed under the same license as the Autoptimize package.
3
  msgid ""
4
  msgstr ""
5
+ "Project-Id-Version: Autoptimize 1.8.0\n"
6
  "Report-Msgid-Bugs-To: http://wordpress.org/tag/autoptimize\n"
7
+ "POT-Creation-Date: 2014-01-17 18:16:35+00:00\n"
8
  "MIME-Version: 1.0\n"
9
  "Content-Type: text/plain; charset=UTF-8\n"
10
  "Content-Transfer-Encoding: 8bit\n"
11
+ "PO-Revision-Date: 2014-MO-DA HO:MI+ZONE\n"
12
  "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
13
  "Language-Team: LANGUAGE <LL@li.org>\n"
14
 
15
+ #: autoptimize.php:117
16
  msgid ""
17
  "Thank you for installing and activating Autoptimize. Please configure it "
18
  "under \"Settings\" -> \"Autoptimize\" to start improving your site's "
19
  "performance."
20
  msgstr ""
21
 
22
+ #: autoptimize.php:123
23
  msgid ""
24
  "Autoptimize has just been updated. Please <strong>test your site now</"
25
  "strong> and adapt Autoptimize config if needed."
85
  msgstr ""
86
 
87
  #: classes/autoptimizeConfig.php:107
88
+ msgid "Exclude scripts from Autoptimize:"
89
  msgstr ""
90
 
91
  #: classes/autoptimizeConfig.php:109
92
  msgid ""
93
+ "A comma-seperated list of scripts you want to exclude from being optimized, "
94
+ "for example 'whatever.js, another.js' (without the quotes) to exclude those "
95
+ "scripts from being aggregated and minimized by Autoptimize."
96
  msgstr ""
97
 
98
  #: classes/autoptimizeConfig.php:112
123
  msgstr ""
124
 
125
  #: classes/autoptimizeConfig.php:130
126
+ msgid "Look for styles only in &lt;head&gt;?"
127
  msgstr ""
128
 
129
  #: classes/autoptimizeConfig.php:132
130
  msgid ""
131
+ "Don't autoptimize CSS outside the head-section. If the cache gets big, you "
132
+ "might want to enable this."
133
  msgstr ""
134
 
135
  #: classes/autoptimizeConfig.php:135
136
+ msgid "Defer CSS loading?"
137
  msgstr ""
138
 
139
  #: classes/autoptimizeConfig.php:137
140
  msgid ""
141
+ "Load optimized CSS only after page load (disables CSS inlining). "
142
+ "<strong>Warning</strong>: <a href=\"http://wordpress.org/plugins/autoptimize/"
143
+ "faq/\" target=\"_blank\">check the FAQ</a> before activating this option!"
144
  msgstr ""
145
 
146
  #: classes/autoptimizeConfig.php:140
147
+ msgid "Inline all CSS?"
148
  msgstr ""
149
 
150
  #: classes/autoptimizeConfig.php:142
151
  msgid ""
152
+ "Inlining all CSS can improve performance for sites with a low pageviews/ "
153
+ "visitor-rate, but may slow down performance otherwise. CSS inlining disables "
154
+ "CSS deferring."
155
+ msgstr ""
156
+
157
+ #: classes/autoptimizeConfig.php:145
158
+ msgid "Exclude CSS from Autoptimize:"
159
  msgstr ""
160
 
161
+ #: classes/autoptimizeConfig.php:147
162
+ msgid "A comma-seperated list of CSS you want to exclude from being optimized."
163
+ msgstr ""
164
+
165
+ #: classes/autoptimizeConfig.php:151
166
  msgid "CDN Options"
167
  msgstr ""
168
 
169
+ #: classes/autoptimizeConfig.php:154
170
  msgid "CDN Base URL"
171
  msgstr ""
172
 
173
+ #: classes/autoptimizeConfig.php:156
174
+ msgid ""
175
+ "Enter your CDN blog root directory URL if you want to enable CDN for images "
176
+ "referenced in the CSS."
177
  msgstr ""
178
 
179
+ #: classes/autoptimizeConfig.php:160
180
  msgid "Cache Info"
181
  msgstr ""
182
 
183
+ #: classes/autoptimizeConfig.php:163
184
  msgid "Cache folder"
185
  msgstr ""
186
 
187
+ #: classes/autoptimizeConfig.php:167
188
  msgid "Can we write?"
189
  msgstr ""
190
 
191
+ #: classes/autoptimizeConfig.php:168
192
  msgid "Yes"
193
  msgstr ""
194
 
195
+ #: classes/autoptimizeConfig.php:168
196
  msgid "No"
197
  msgstr ""
198
 
199
+ #: classes/autoptimizeConfig.php:171
200
  msgid "Cached styles and scripts"
201
  msgstr ""
202
 
203
+ #: classes/autoptimizeConfig.php:175
204
  msgid "Save aggregated script/css as static files?"
205
  msgstr ""
206
 
207
+ #: classes/autoptimizeConfig.php:177
208
+ msgid ""
209
+ "By default files saved are static css/js, uncheck this option if your "
210
+ "webserver doesn't properly handle the compression and expiry."
211
  msgstr ""
212
 
213
+ #: classes/autoptimizeConfig.php:183
214
  msgid "Save Changes"
215
  msgstr ""
216
 
217
+ #: classes/autoptimizeConfig.php:184
218
  msgid "Save Changes and Empty Cache"
219
  msgstr ""
220
 
221
+ #: classes/autoptimizeConfig.php:192
 
 
 
 
222
  msgid "futtta about"
223
  msgstr ""
224
 
225
+ #. #-#-#-#-# plugin.pot (Autoptimize 1.8.0) #-#-#-#-#
226
  #. Plugin Name of the plugin/theme
227
+ #: classes/autoptimizeConfig.php:194
228
  msgid "Autoptimize"
229
  msgstr ""
230
 
231
+ #: classes/autoptimizeConfig.php:195
232
  msgid "WordPress"
233
  msgstr ""
234
 
235
+ #: classes/autoptimizeConfig.php:196
236
  msgid "Web Technology"
237
  msgstr ""
238
 
239
+ #: classes/autoptimizeConfig.php:201
240
+ msgid "Do not donate for this plugin!"
241
+ msgstr ""
242
+
243
+ #: classes/autoptimizeConfig.php:262
244
  msgid "Autoptimize Options"
245
  msgstr ""
246
 
247
+ #: classes/autoptimizeConfig.php:309 classes/autoptimizeConfig.php:316
248
  msgid "Settings"
249
  msgstr ""
250
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Tags: css, html, javascript, js, optimize, speed, cache, data-uri, aggregate, mi
4
  Donate link: http://blog.futtta.be/2013/10/21/do-not-donate-to-me/
5
  Requires at least: 2.7
6
  Tested up to: 3.8
7
- Stable tag: 1.7.3
8
 
9
  Autoptimize speeds up your website and helps you save bandwidth by aggregating and minimizing JS, CSS and HTML.
10
 
@@ -44,6 +44,24 @@ CSS in general should go in the head of the document. Recently a.o. Google start
44
  * put the resulting CSS in the head of your page (should be in the header.php file of your theme)
45
  * check the option to defer CSS
46
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
47
  = How does CDN work? =
48
 
49
  Starting from version 1.7.0, CDN is activated upon entering the CDN blog root directory (e.g. http://cdn.example.net/wordpress/). If that URL is present, it will used for all Autoptimize-generated files (i.e. aggregated CSS and JS), includinng background-images in the CSS (when not using data-uri's).
@@ -64,7 +82,7 @@ There have been reports of sightings of javascript errors when using Autoptimize
64
 
65
  = Problems with CSS of Kickstart theme when on WP Engine =
66
 
67
- Although multiple users are succesfully running Autoptimize on WP Engine, there is [one confirmed issue when using the Kickstart-theme with Autoptimize on WP Engine](http://wordpress.org/support/topic/zero-lenght-file-with-css-optimization). The problem is that Autoptimize can't source in the import, leading to an empty CSS-file (which does not happen wen not on WP Engine). As a workaround you can link to the CSS-file from within your header.php, as suggested by [Ozum of fortibase.com](http://www.fortibase.com/)
68
 
69
  = Configuring & Troubleshooting Autoptimize =
70
 
@@ -103,9 +121,21 @@ You can report problems on the [wordpress.org support forum](http://wordpress.or
103
 
104
  == Changelog ==
105
 
 
 
 
 
 
 
 
 
 
 
 
 
106
  = 1.7.3 =
107
  * improvement: remove cache + options on uninstall as [requested by Gingerbreadmen](http://wordpress.org/support/topic/wp_options-entries)
108
- * improvement: set .htaccess to allow PHP execution in wp-content/cache/autoptimize when saving optimized files as PHP, as suggested by (David Mottershead of bermuda4u.com}[http://www.bermuda4u.com/] but forbid PHP execution when saving aggregated script/css as static files (except for multisite).
109
  * bugfix: avoid Yoast SEO sitemaps going blank (due optimization of Yoast's dynamically built XML/XSL) as reported by [Vance Hallman](http://www.icefishing.co) and [Armand Hadife](http://solar-flag-pole-lights.com/). More info on this issue [can be found on my blog](http://blog.futtta.be/2013/12/09/blank-yoast-seo-sitemaps-no-more/).
110
  * smaller changes to readme.txt
111
 
@@ -117,7 +147,7 @@ You can report problems on the [wordpress.org support forum](http://wordpress.or
117
  = 1.7.1 =
118
  * New: support for mapped domains as suggested by [Michael for tiremoni.com](http://tiremoni.com/)
119
  * Added an .htaccess to wp-content/cache/autoptimize to overwrite other caching directives (fixing a problem with WP Super Cache's .htaccess really, [as reported](http://wordpress.org/support/topic/expiresmax-age-compatibility-with-supercache) by [Hugh of www.unitedworldschools.org](http://www.unitedworldschools.org/))
120
- * bugfix: Autoptimize broke data:uri's in CSS in some cases as reported by [Joseph from blog-it-solutions.de](http://www.blog-it-solutions.de/)
121
  * bugfix: avoid PHP notice if CSS exclusion list is empty
122
  * moved "do not donate"-image into plugin
123
 
4
  Donate link: http://blog.futtta.be/2013/10/21/do-not-donate-to-me/
5
  Requires at least: 2.7
6
  Tested up to: 3.8
7
+ Stable tag: 1.8.0
8
 
9
  Autoptimize speeds up your website and helps you save bandwidth by aggregating and minimizing JS, CSS and HTML.
10
 
44
  * put the resulting CSS in the head of your page (should be in the header.php file of your theme)
45
  * check the option to defer CSS
46
 
47
+ = Should you inline all CSS? =
48
+
49
+ The short answer: if you just want to improve your (mobile) pagespeed score; yes, otherwise maybe not.
50
+
51
+ Back in the days CSS optimization was easy; put all CSS in your head, aggregating everything in one CSS-file per media-type and you were good to go. But ever since Google included mobile in PageSpeed Insights and started complaining about redering blocking CSS, things got messy (see "deferring CSS" elsewhere in this FAQ). One of the solutions is inlining all your CSS, which as of Autoptimize 1.8.0 is supported.
52
+
53
+ Inlining all CSS has one clear advantage (better PageSpeed score) and one big disadvantage; your base HTML-page gets significantly bigger. The fact that the HTML gets heavier as such is not a huge issue; when looking at performance for a single page request/ response, performance will be better, as there's no overhead of one or more extra requests for CSS-files. But when looking at a test that includes multiple requests (let's say 5), performance will be worse, as the CSS-payload is sent over whereas normally the seperate CSS-files would not need to be sent any more as they would be in cache.
54
+
55
+ So the choice should be based on your answer to some site-specific questions; what is your site's bounce rate? How many pages per visit do your visitors request? If you have a high bounce rate and a low number of average pages per visit, inlining CSS looks like a good idea. But with a high number of pages/ visit, it's probably not a good idea. Except if all you care about is a stellar PageSpeed-score, off course.
56
+
57
+ = What can I do with the API? =
58
+
59
+ A whole lot; there are filters you can use to conditionally disable Autoptimize per request, to change the CSS- and JS-excludes, to change the limit for CSS background-images to be inlined in the CSS, to define what JS-files are moved behing the aggregated on, to change the defer-attribute on the aggregated JS script-tag, There are examples for all filters in autoptimize_helper.php_example.
60
+
61
+ = How can I use/ activate autoptimize_helper.php_example? =
62
+
63
+ Copy it to /wp-content/plugins/autoptimize_helper.php and activate it in WordPress' plugin page. After that you can simple remove the one of the comment-sequences (double-slash) to activate one (or more) of the functions in there.
64
+
65
  = How does CDN work? =
66
 
67
  Starting from version 1.7.0, CDN is activated upon entering the CDN blog root directory (e.g. http://cdn.example.net/wordpress/). If that URL is present, it will used for all Autoptimize-generated files (i.e. aggregated CSS and JS), includinng background-images in the CSS (when not using data-uri's).
82
 
83
  = Problems with CSS of Kickstart theme when on WP Engine =
84
 
85
+ Although multiple users are succesfully running Autoptimize on WP Engine, there is [one confirmed issue when using the Kickstart-theme with Autoptimize on WP Engine](http://wordpress.org/support/topic/zero-lenght-file-with-css-optimization). The problem is that Autoptimize can't source in the import, leading to an empty CSS-file (which does not happen when not on WP Engine). As a workaround you can link to the CSS-file from within your header.php, as suggested by [Ozum of fortibase.com](http://www.fortibase.com/)
86
 
87
  = Configuring & Troubleshooting Autoptimize =
88
 
121
 
122
  == Changelog ==
123
 
124
+ = 1.8.0 =
125
+ * New: Option to inline all CSS [as suggested by Hamed](http://wordpress.org/support/topic/make-style-sheet-inline)
126
+ * New: set of filters to provide a simple API to change Autoptimize behavior (e.g. replace "defer" with "async", disabling Autoptimization on certain pages, specificy non-aggregatable script to be moved after aggregated one (cfr. http://wordpress.org/support/topic/feature-request-some-extra-options?replies=14), size of image to be data-urized). More info in the included autoptimize_helper.php_example.
127
+ * Improvement: exclude (css in) noscript-tags as [proposed by belg4mit](http://wordpress.org/support/topic/feature-suggestion-noscript-for-css)
128
+ * Improvement: switch default delivery of optimized CSS/JS-files from PHP to static files
129
+ * Updated [upstream CSS minifier](https://github.com/tubalmartin/YUI-CSS-compressor-PHP-port/commit/fb33d2ffd0963692747101330b175a80173ce21b)
130
+ * Improvement (force gzip of static files) and Bugfix (force expiry for dynamic files, thanks to [Willem Razenberg](http://www.column-razenberg.nl/) in .htaccess
131
+ * Improvement: fail gracefully when things go wrong (e.g. CSS import resulting in empty aggregated CSS-files [reported by Danka](http://wordpress.org/support/topic/very-good-332) or when the theme is broken [as seen by Prateek Gupta](http://wordpress.org/support/topic/js-optimization-break-site-white-page-issue?replies=14#post-5038941))
132
+ * Updated translations and Polish added (thanks to [Jakub Sierpinski](http://www.sierpinski.pl/)).
133
+ * Bugfix: stop import-statements in CSS comments to be taken into acccount [hat tip to Josef from blog-it-solutions.de](http://www.blog-it-solutions.de/)
134
+ * Bugfix: fix for blur in CSS breakeage as [reported by Chris of clickpanic.com](http://blog.clickpanic.com/)
135
+
136
  = 1.7.3 =
137
  * improvement: remove cache + options on uninstall as [requested by Gingerbreadmen](http://wordpress.org/support/topic/wp_options-entries)
138
+ * improvement: set .htaccess to allow PHP execution in wp-content/cache/autoptimize when saving optimized files as PHP, as suggested by (David Mottershead of bermuda4u.com)[http://www.bermuda4u.com/] but forbid PHP execution when saving aggregated script/css as static files (except for multisite).
139
  * bugfix: avoid Yoast SEO sitemaps going blank (due optimization of Yoast's dynamically built XML/XSL) as reported by [Vance Hallman](http://www.icefishing.co) and [Armand Hadife](http://solar-flag-pole-lights.com/). More info on this issue [can be found on my blog](http://blog.futtta.be/2013/12/09/blank-yoast-seo-sitemaps-no-more/).
140
  * smaller changes to readme.txt
141
 
147
  = 1.7.1 =
148
  * New: support for mapped domains as suggested by [Michael for tiremoni.com](http://tiremoni.com/)
149
  * Added an .htaccess to wp-content/cache/autoptimize to overwrite other caching directives (fixing a problem with WP Super Cache's .htaccess really, [as reported](http://wordpress.org/support/topic/expiresmax-age-compatibility-with-supercache) by [Hugh of www.unitedworldschools.org](http://www.unitedworldschools.org/))
150
+ * bugfix: Autoptimize broke data:uri's in CSS in some cases as reported by [Josef from blog-it-solutions.de](http://www.blog-it-solutions.de/)
151
  * bugfix: avoid PHP notice if CSS exclusion list is empty
152
  * moved "do not donate"-image into plugin
153