Title: LC Scripts Optimizer
Author: LCweb
Published: <strong>2016 年 10 月 22 日</strong>
Last modified: 2026 年 3 月 9 日

---

搜索插件

![](https://ps.w.org/lc-scripts-optimizer/assets/banner-772x250.png?rev=3205912)

![](https://ps.w.org/lc-scripts-optimizer/assets/icon.svg?rev=2334195)

# LC Scripts Optimizer

 作者：[LCweb](https://profiles.wordpress.org/lcweb-projects/)

[下载](https://downloads.wordpress.org/plugin/lc-scripts-optimizer.zip)

 * [详情](https://cn.wordpress.org/plugins/lc-scripts-optimizer/#description)
 * [评价](https://cn.wordpress.org/plugins/lc-scripts-optimizer/#reviews)
 *  [安装](https://cn.wordpress.org/plugins/lc-scripts-optimizer/#installation)
 * [开发进展](https://cn.wordpress.org/plugins/lc-scripts-optimizer/#developers)

 [支持](https://wordpress.org/support/plugin/lc-scripts-optimizer/)

## 描述

Your theme and each plugin add several JavaScript and CSS files to your webpages
and each of them **requires a while to be handled, downloaded and executed by browsers**.

This makes your website heavy and slow. Even using a static cache plugin, for fresh
viewers (and **page-speed rankers!**) what matters is the webpage weight and how
fast it completes loading all of its scripts.

The LCweb optimizer is a resource-friendly solution to **merge and optimize them**:
dramatically reducing the number of HTTP requests your webpages perform and speeding-
up their rendering!

You can also decice **where scripts have to be used** in the website. Do you only
have a gallery in a specific page? Why loading its scripts everywhere. Optimize 
every bit, in the simplest way possible.

Extra features: HTML code minifier and cache-friendly file headers!
 PS: it is also
compatible with other WP optimizers (Redis, W3 total cache, WP-super-cache, etc),
offering a great combo to optimize wordpress all-around!

 

#### 🌟 Features list in detail

 * lightweigt and ready out-of-the-box
 * compatible with any theme and any script
 * JavaScript/CSS files merge into a single static file
 * filter where scripts have to be used by page URL and/or regular expression
 * option to singularly exclude every JavaScript/CSS files from the optimization
   engine
 * CSS @import code processing
 * CSS minification
 * JavaScript minification
 * HTML minification
 * HTACCESS file headers to make browsers cache static resources
 * every optimization system can be toggled for the maximum compatibility
 * testing mode to tune the plugin settings without affecting visitors
 * compatible with other WP cache plugins

 

#### 📝 Notes

 * Scripts/styles must be properly enqueued through WP register functions
 * Static files creation requires writing permissions in wp-content folder

## 屏幕截图

 * [[
 * Settings 1
 * [[
 * Settings 2
 * [[
 * Settings 3

## 安装

 1. Upload `lc-scripts-optimizer` to the `/wp-content/plugins/` directory
 2. Activate the plugin through the ‘Plugins’ menu in WordPress
 3. If not automatically moved to the plugin settings page, you find the menu item 
    under the WordPress “tools” one
 4. Check system status and eventually unlock writing permissions
 5. Go on “scripts filter” tab and click on “fetch again” button to store scripts. 
    If the website is not publicly accessible by cURL, simply browser it to let the
    plugin fetch used scripts
 6. Tune it as you prefer and save the settings
 7. NB: is strongly suggested to start using the “test mode” and to keep the browser’s
    console opened to scan for eventual conflicts

## 评价

此插件暂无评价。

## 贡献者及开发者

「LC Scripts Optimizer」是开源软件。 以下人员对此插件做出了贡献。

贡献者

 *   [ LCweb ](https://profiles.wordpress.org/lcweb-projects/)

[帮助将「LC Scripts Optimizer」翻译成简体中文。](https://translate.wordpress.org/projects/wp-plugins/lc-scripts-optimizer)

### 对开发感兴趣吗?

您可以[浏览代码](https://plugins.trac.wordpress.org/browser/lc-scripts-optimizer/)，
查看[SVN仓库](https://plugins.svn.wordpress.org/lc-scripts-optimizer/)，或通过[RSS](https://plugins.trac.wordpress.org/log/lc-scripts-optimizer/?limit=100&mode=stop_on_copy&format=rss)
订阅[开发日志](https://plugins.trac.wordpress.org/log/lc-scripts-optimizer/)。

## 更新日志

#### 2.1.0

 * new: more file types covered by HTACCESS static files cache headers
 * new: better integration with Elementor builder mode
 * new: now recognizing data:text/javascript
 * fixed: HTACCESS static files cache headers not managed on settings saving
 * fixed: inline style/script codes ignored during the scripts parsing

#### 2.0.0

 * new: complete plugin code revision and overhaul
 * new: settings engine
 * new: scripts filter’s user interface to better orientate among scripts
 * new: improved compatibility with most popular page builders
 * added: creation date attribute for better merged scripts file cache
 * added: HTACCESS static file headers system
 * added: option to not minify merged scripts
 * added: compatibility with scripts being enqueued with async/defer instruction
 * added: button to remove fetched script from “filter” interface
 * removed: optimized scripts delivery through static URL (useless and dangerous)

#### 1.4.0

 * improved get_options performances (w/ WP 6.4 compatibility)
 * scripts tracked and added to the settings page also navigating the website

#### 1.3.2

 * inline javascript codes attached to scripts now appended before them

#### 1.3.1

 * better javascript for the settings page

#### 1.3

 * added fields for URL-based scripts exclusion from the engine
 * improved Elementor compatibility
 * better HTML minification start hook

#### 1.2

 * added HTML minification engine
 * file_get_contents used to recall local files, working with hidden websites
 * fixed CSS bad paths composition
 * fixed CSS @font-face placement
 * fixed existing cached files check

#### 1.1.2

 * Elementor Compatibility

#### 1.1.1

 * Better scripts fetching in “Scripts Filter”
 * Elementor Compatibility (requires jQuery to be ignored during optimization)

#### 1.1

 * Added options to exclude CSS and JS concatenation (to just use scripts filter)
 * Added testing mode to check optimizations only if logged as WP admin
 * Added sticky settings update button
 * Better engine initialization code
 * Minor UI improvements

#### 1.0

Initial release

## 额外信息

 *  版本 **2.1.0**
 *  最后更新：**3 月前**
 *  活跃安装数量 **10+**
 *  WordPress 版本 ** 5.0 或更高版本 **
 *  已测试的最高版本为 **6.9.4**
 *  PHP 版本 ** 7.0 或更高版本 **
 *  语言
 * [English (US)](https://wordpress.org/plugins/lc-scripts-optimizer/)
 * 标签
 * [cache](https://cn.wordpress.org/plugins/tags/cache/)[compress](https://cn.wordpress.org/plugins/tags/compress/)
   [minification](https://cn.wordpress.org/plugins/tags/minification/)[seo](https://cn.wordpress.org/plugins/tags/seo/)
   [speed](https://cn.wordpress.org/plugins/tags/speed/)
 *  [高级视图](https://cn.wordpress.org/plugins/lc-scripts-optimizer/advanced/)

## 评级

尚未提交反馈。

[Your review](https://wordpress.org/support/plugin/lc-scripts-optimizer/reviews/#new-post)

[查看全部评论](https://wordpress.org/support/plugin/lc-scripts-optimizer/reviews/)

## 贡献者

 *   [ LCweb ](https://profiles.wordpress.org/lcweb-projects/)

## 支持

有话要说吗？是否需要帮助？

 [查看支持论坛](https://wordpress.org/support/plugin/lc-scripts-optimizer/)

## 捐助

您愿意支持这个插件的发展吗?

 [ 捐助此插件 ](https://lcweb.it/donations/)