這個外掛並未在最新的 3 個 WordPress 主要版本上進行測試。開發者可能不再對這個外掛進行維護或提供技術支援,並可能會與更新版本的 WordPress 產生使用上的相容性問題。

PUZZLER is JS + CSS combine

描述

Puzzler – it excellent js/css aggregator for advanced users:

  • Automatically combines all enqueued scripts/styles into a single file, for faster loading blog.
  • Starts immediately without setting.
  • You can adds scripts and styles in queue, change the order, edit – and Puzzler automatically make recombines.

Puzzler – don’t worry be happy.

Require PHP 5.4 or high.

You should remember 3 key rules before using:

Key rule 1

All scripts and styles must include ONLY 1 time and ONLY in 1 place, e.g. in wp_enqueue_scripts hook

Key rule 2

Styles(css) aggregation perform only for media=’all’ ( without alternative stylesheets, titles, conditionals )

Key rule 3

Avoid register/enqueue scripts/styles in conditional expressions
add_action(‘wp_enqueue_scripts’, ‘my_enqueue_scripts’);
function my_enqueue_scripts() {

  // -- don't do it !
  if ( is_single() || is_page() ) { 
      wp_enqueue_script('myscript');
  }

  // -- correct !
  wp_enqueue_script('myscript');

}

Features

  • Auto detect files change
  • Autocorrect internal links in the CSS after aggregation ( url/src )
  • Auto +20 scores in Google PageSpeed Insights
  • Async/lazy load aggregated scripts/styles
  • Windows compatible

螢幕截圖

  • Puzzler settings

安裝

  1. Make sure PHP version is 5.4 or high.
  2. Create in your wp-content directory, cache folder with 0777 permissions
  3. Upload the plugin files to the plugins/puzzler directory, or install the plugin through the WordPress plugins screen directly.
  4. Activate the plugin through the ‘Plugins’ screen in WordPress
  5. You can configure plugin through “Puzzler” item in main admin menu

常見問題

None FAQs

評價

2016年9月3日 1 reply
This plugin completely broke my site. My server fulfills the requirements but changing any settings of the plugin didn't help at all but at least after deactivating it everything was back to normal. What a relief. I took a look at the compressed files it genereated and already saw that this would not work without bothering to look into details. Also: I'm pretty sure relying on a cache folder with CHMOD 777 is bad practice.
閱讀全部4個評價

貢獻者及開發者

“PUZZLER is JS + CSS combine” 是一個開源的軟體。以下的人對這個外掛作出了貢獻。

貢獻者

將 PUZZLER is JS + CSS combine 外掛本地化為台灣繁體中文版。

對開發相關資訊感興趣?

任何人均可瀏覽程式碼、查看 SVN 存放庫,或透過 RSS 訂閱開發記錄

修改日誌

1.0

  • First version