[WordPress] 外掛分享: GDPR Cache Scripts & Styles

WordPress 外掛 GDPR Cache Scripts & Styles 的封面圖片。

前言介紹

  • 這款 WordPress 外掛「GDPR Cache Scripts & Styles」是 2022-09-14 上架。
  • 目前有 100 個安裝啟用數。
  • 上一次更新是 2023-01-24,距離現在已有 830 天。超過一年沒更新,安裝要確認版本是否可用。以及後續維護問題!
  • 外掛最低要求 WordPress 5.8 以上版本才可以安裝。
  • 外掛要求網站主機運作至少需要 PHP 版本 7.2 以上。
  • 有 1 人給過評分。
  • 還沒有人在論壇上發問,可能目前使用數不多,還沒有什麼大問題。

外掛協作開發者

strackerphil-1 |

外掛標籤

CCPA | GDPR | privacy | asset cache | script cache |

內容簡介

這是一個可以一鍵自動從您的本地網站服務外部資源的解決方案。

不需要設置和編程 – 啟用插件後就可以不再管它了。

1. 免責聲明

此插件不保證能使您的網站符合 GDPR 標準。作為網站運營者,您始終有責任驗證此插件對您是否有效並在載入訪問者的瀏覽器之前收集外部腳本的同意。

2. 如何運作

簡單來說,外部文件會下載到您的 WordPress 安裝(上傳文件夾中)中,然後從那裡提供服務。

更多細節:

該插件掃描每一個通過wp_enqueue_script()和wp_enqueue_style() 排隊的URL。當偵測到外部URL時,就會將該文件保存到您的上傳文件夾中並從那裡提供服務。

此外,它也會掃描 CSS 文件的內容以尋找外部依賴,並將這些文件也保存到您的上傳文件夾中!

需要注意的是,出於技術原因,我們無法掃描 JS 文件以查找此類依賴關係 – JS 文件始終可以注入外部資源

沒有輸出緩衝:

此插件不添加任何 "輸出緩衝",而是掃描通過推薦的 WordPress 函數排列的 URL。

因此, GDPR Cache Scripts & Styles 對您的反應時間幾乎沒有性能影響,不管您的網站有多大。

背景工作者:

為了加快網站的加載速度,所有資源都是在後台進行下載的:當偵測到新的資源,或快取檔案過期時,就會排隊一個背景工作任務。

這個佇列然後會被處理在非同步的過程中; 處理佇列的同時,您的網站可能還會暫時提供外部資源 – 通常在一兩分鐘內就可以處理完畢。

3. 選項頁面

您可以在 "工具 > GDPR 快取" 中找到此插件的選項頁面。在該頁面上,您可以刷新和清除您的網站快取。

在這裡,您還可以查看所有本地快取的檔案列表,以及每個檔案的到期日期-當檔案過期時,插件就會從遠端伺服器下載新的版本。

另外,當您停用插件時,整個快取也會被清除(所有檔案都會被刪除,相關的 DB 值也會被重置)

4. 基於測試

我們已經使用以下主題和插件對此插件進行了測試:

區塊編輯器(透過自定義CSS的Google字型)
Divi(參見下面的 "Divi 配置")
Elementor
Jetpack(特別是加入了 "site accelerator" 等效能選項)
Fonts Plugin | Google Fonts Typography
可用於多網站網絡

大多數其他插件和主題也能與此插件一起使用。如果遇到任何問題,請告訴我們,這樣我們就可以改進這個插件 👍

原文外掛簡介

One-click solution to automatically serve external assets from your local website.
No configuration and no coding required – activate the plugin and forget about it.
1. Disclaimer
This plugin does not provide any guarantees of making your website GDPR-compliant. As a website operator, you are always responsible to verify if this plugin works for you and collect consent for external scripts before loading them in the visitor’s browser.
2. How it works
Short: External files are downloaded to your WordPress installation (into the uploads-folder) and then served from there.
More details:
The plugin scans every URL that is enqueued via wp_enqueue_script() and wp_enqueue_style(). When detecting an external URL, that file is saved to your uploads-folder and served from there.
It also scans the contents of CSS files for external dependencies and also saves those files to your uploads-folder!
Heads-up: For technical reasons, we cannot scan the contents of JS files for such dependencies – JS files can always inject external assets
No Output Buffer:
This plugin does not add any “output buffering” but scans the URLs which are enqueued via recommended WordPress functions.
As a result, GDPR Cache Scripts & Styles has practically no performance impact on your response time, no matter how big your website is.
Background worker:
To speed up your website’s loading time, all assets are downloaded in a background process: When a new asset is detected, or a cached file expires, a worker-task is enqueued.
The queue is then processed in an asynchronous process; while the queue is processed, your website could still serve the external assets for a while – usually the queue is processed within one or two minutes.
3. Options Page
You’ll find the plugin options page at “Tools > GDPR Cache”. On that page you can refresh and purge your website’s cache.
Here you can also review a full list of all files that are locally cached, and review the expiration date of each file – when a file expires, the plugin downloads a new version of it from the remote server.
Additionally, when you deactivate the plugin, the entire cache is purged (all files are deleted and relevant DB values are reset)
4. Tested with
We’ve tested this plugin with the following themes and plugins:

Block Editor (embedding Google Fonts via the Customizer’s “Additional CSS”)
Divi (see “Configuration for Divi” below)
Elementor
Jetpack (specially with Performance options like “site accelerator”)
Fonts Plugin | Google Fonts Typography
Works on multisite networks

Most other plugins and themes will work with this plugin as well. If you encounter any issues, please let us know, so we can improve this plugin 👍

各版本下載點

  • 方法一:點下方版本號的連結下載 ZIP 檔案後,登入網站後台左側選單「外掛」的「安裝外掛」,然後選擇上方的「上傳外掛」,把下載回去的 ZIP 外掛打包檔案上傳上去安裝與啟用。
  • 方法二:透過「安裝外掛」的畫面右方搜尋功能,搜尋外掛名稱「GDPR Cache Scripts & Styles」來進行安裝。

(建議使用方法二,確保安裝的版本符合當前運作的 WordPress 環境。


1.0.0 | 1.0.1 | 1.0.2 | 1.0.3 | 1.0.4 | 1.0.5 | 1.0.6 | 1.0.7 | trunk |

延伸相關外掛(你可能也想知道)

文章
Filter
Apply Filters
Mastodon