前言介紹
- 這款 WordPress 外掛「WP Scripts & Styles Optimizer」是 2016-07-05 上架。
- 目前有 100 個安裝啟用數。
- 上一次更新是 2017-10-10,距離現在已有 2763 天。超過一年沒更新,安裝要確認版本是否可用。以及後續維護問題!
- 外掛最低要求 WordPress 4.4.0 以上版本才可以安裝。
- 有 15 人給過評分。
- 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。
外掛協作開發者
外掛標籤
css | styles | scripts | javascript | into header |
內容簡介
優化所包含的 JavaScript 和 CSS 文件可能是一個非常重要的事情,如果您想要更快的網站。許多 WordPress 插件帶有多個第三方和/或自己的 JavaScript 文件,這些文件通常會在您網站的每個頁面上包含。在最糟糕的情況下,您的網站上可能會包含多個相同的文件。這會使您的網站變慢!
但是,“渲染阻塞”也很容易使網站變慢。在您的網站標頭中包含的每個外部 JavaScript 或 CSS 文件都會阻止網站渲染,直到所有文件完全處理完畢。通常會將所有這些腳本和樣式(除了關鍵 CSS)移至您網站的頁腳,以便不再阻止渲染並加快網站加載速度。
這就是 WP Script Optimizer 的用途!它使您能夠控制每個註冊的 JavaScript 或 CSS 文件的輸出。您可以輕鬆創建規則或完全停用文件。您還可以將文件移至您網站的標頭或頁腳。
請查看以下列表以了解所有目前可用的和計劃中的功能。如果您喜歡此插件,請投票並留言。這將非常有幫助。
您目前可以使用 WP Script Optimizer 做什麼
獲取您網站包含的所有前端 JavaScript 和 CSS 文件的概述(按類別劃分)
為您想要控制的多個單獨頁面或全局設置腳本和樣式
更改特定 JavaScript 或 CSS 或全部通過位置(標頭/頁腳)
如不需要,完全停用特定的 JavaScript 或 CSS 文件
通過使用 wordpress 的條件標籤輕鬆創建邏輯規則,以控制是否包含文件
您未來可以使用 WP Script Optimizer 做什麼(計劃中但目前未實現)
縮小和/或加密 JavaScript 和 CSS 文件
包含您自己的 JavaScript/CSS 文件或 JavaScript/CSS 內聯代碼,而不需要通過 functions.php 手動執行
將額外代碼添加到任何已註冊的 JavaScript 或 CSS 文件中
將一種類型(JS 或 CSS)的兩個或更多(或所有)文件連接起來,以加快加載時間
更好地瞭解相關方和其相關性
…歡迎提出建議 :)
重要 – 請閱讀:
該插件無法決定特定情況下是否需要文件。您的設置有可能破壞您網站的功能。如果是這種情況,您可以輕鬆通過管理面板更改或刪除您的設置,以便一切恢復到以前的狀態。
簡而言之:您必須知道自己在做什麼😉
如果您在使用此插件時遇到任何問題,請與我聯繫,以便我修復問題。請勿在未給我矯正問題的機會下給予負面評論。謝謝。
原文外掛簡介
Optimization of included JavaScript- and CSS-files can be a very important thing, if you want a faster site. Many WordPress plugins comes with multiple third-party and/or own JavaScript-files that are then often be included on every page of your site. In worst cases you have more than one of the same file included on your site. That slows down your site!
But also “Render blocking” can easily slow down a website. Every external JavaScript- or CSS-file, that is included in the head of your site, blocks the site from rendering, until all files are completely processed. It’s a common practice to move all these Scripts and Styles (except critical CSS) to the footer of your site, so the rendering is no longer blocked and your website loads faster.
This is where WP Script Optimizer helps you! It makes it possible to control the output of every registered JavaScript or CSS-file. You can easily create rules for it or deactivate files completely. You can also move files to the footer of your site or vice versa.
Check out the following lists for all currently avaiable and planned features. If you like this plugin, please upvote and comment. That would be really helpful.
What you can currently do with WP Script Optimizer
Get an overview of all frontend JavaScript and CSS files, that are included on your site (divided in categories)
Control scripts and styles for as many single pages as you want or simply globally
Change the positioning (Header/Footer) of specific JavaScripts / CSS or all at once
Deactivate specific Javascripts or CSS-files completely, if not needed
Easily create logical rules to control under which conditions a file is included or not (by use of wordpress’s conditional tags)
What you can do in future with WP Script Optimizer (planned, but not currently implemented)
Minify and/or encrypt JavaScript- and CSS-files
Include your own JavaScript/CSS files or JavaScript/CSS inline code, without do it manually through functions.php
Add extra code to any registered JavaScript or CSS-file
Concatenate two or more (or all) files of one type (JS or CSS) to speed up loading times
Better overview of dependents and its dependencys
… feel free to make suggestions 🙂
IMPORTANT – Please read:
This plugin can not decide if a file is needed or not needed in a specific situation. Your settings have the potential to break features and functions of your site. If that is the case, you can easily change or delete your settings via the admin panel, so everything will be like it was before.
tl;dr: you have to know what you’re doing 😉
If You had any problems with this plugin, please contact me, so i could fix it. Please don’t write a negative review without gave me the chance to correct any issues. Thanks.
各版本下載點
- 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
- 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「WP Scripts & Styles Optimizer」來進行安裝。
(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。
0.1.0 | 0.1.1 | 0.1.2 | 0.2.1 | 0.2.2 | 0.3.0 | 0.4.0 | 0.4.1 | 0.4.2 | 0.4.3 | 0.4.4 | 0.4.5 | trunk |
延伸相關外掛(你可能也想知道)
Header and Footer Scripts 》如果您正在運行 WordPress 網站,早晚都需要將某種代碼插入到您的網站上。最有可能的是網頁分析代碼,例如 Google Analytics,或者是社交媒體腳本、某些 CSS ...。
CSS & JavaScript Toolbox 》感謝您查看我們的程式碼片段外掛。我相信它將完全符合您的需求。, 適用於以下情況:, , 前端修改(無需修改主題文件), 添加功能(無需修改functions.php), ...。
Speed Up – JavaScript To Footer 》這個小巧的 WordPress 外掛(2 KB)將 JavaScript 移到頁尾,增加頁面載入速度。, 注意:此外掛只會在其他外掛和主題正確添加 JavaScripts 的情況下運作。, ...。
Speed Up – Browser Caching 》這個大小為 10 Kb 的小型 WordPress 外掛可以啟用 Apache 網頁伺服器的瀏覽器快取功能,幫助瀏覽器快取靜態檔案的本地副本,提升網頁載入速度。, 不需要任何...。
Cache External Scripts 》當嘗試優化 Google Pagespeed分數時,常常會有一個腳本引起「Leverage browser caching」規則彈出:即Google自己的gtag.js和/或analytics.js文件…, 使...。
Greenshift Smart Code AI 》- SMART CODE AI是一款開創性的WordPress外掛,利用人工智慧的能力,輔助您輕鬆建立自訂的程式碼片段。, - 功能與優勢:, - AI輔助建議:先進的AI技術即時...。
Speed Up – Clean WP 》這個小巧的 WordPress 外掛(5 Kb)會透過移除 comment-reply.min.js 和 jquery-migrate.js 腳本、停用「嵌入式」(embeds)和「表情符號」(emoji)功能,以...。
Header and Footer Scripts Adder 》許多 WordPress 主題沒有任何選項在您的網站中插入標頭和頁尾標籤 或
Version Assets 》此外掛可以自動應用基於內容的版本號,以優化瀏覽器快取效能。。
Optimize Scripts & Styles 》Optimize Scripts & Styles是一個WordPress外掛程式,它在結合、減小檔案體積和快取javascript和css檔案時優化您的網站。這將有助於減少提供的檔案數量及...。
OPCache Scripts 》使用此外掛程式顯示有關您的伺服器的 OPCache 詳細資訊,包括記憶體使用情況、所有快取腳本的清單以及基於檔案系統樹的有用的記憶體使用情況視覺化。, 此外掛...。
Enhanced Header / Footer Injections 》增強式 Header / Footer Injections 外掛允許您針對每個頁面,將 HTML 代碼插入到您的範本的標頭和頁腳部分。此外,此外掛還與自訂文章類型、封存頁面、404 ...。
WP cdnjs 》利用強大而免費的CDNjs加速您的網站。此外掛可讓您搜尋全部 http://cdnjs.com 的庫資料並將它們加入您的網站中。, 由 Audioscavenger 自豪地更新。, 需要 PHP...。
Conditionally Load CF7 》Contact Form 7 在預設設置下會在每個頁面載入其 JavaScript 和 CSS 樣式表,這會拖慢頁面載入速度,並消耗伺服器和客戶端資源。使用此外掛程式來控制腳本載...。
WP Enqueue 》這個外掛可以大大簡化腳本 (scripts) 和樣式 (styles) 的加載,您可以透過獨立的選項菜單頁面進行管理。, 您可以把腳本和樣式加載到頁面的 head 或 footer ,...。