FISHWINK Consent WP Registry grade A. No security issues foundWP RegistryNo security issues foundOpen the reportA
FISHWINK Cookie Consent Plugin
Install
Upload it under Plugins → Add New Plugin → Upload Plugin, then activate.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/fishwink/gfw-consent/releases/download/v1.0.16/gfw-consent-1.0.16.zipLightweight WordPress cookie consent plugin for FISHWINK (GoFishWink) client sites. The slug, option keys, and REST routes remain gfw-consent / gfw_consent for backwards compatibility with existing installs — only user-facing labels carry the FISHWINK name.
What it does
- Blocks known marketing/analytics/functional scripts at PHP render time via output buffering, so nothing fires until the visitor consents.
- Swaps blocked iframes (YouTube, Vimeo, Maps) with click-to-load placeholders.
- Injects Google Consent Mode v2 defaults (denied) and pushes
consent updatewhen the user decides. - Honors the Global Privacy Control browser signal.
- Logs every consent event (accept/reject/custom/withdraw/gpc_auto) to a custom DB table with hashed IP, policy version, categories, and URL — a demonstrable audit trail.
- Auto-generates a cookie policy via
[gfw_consent_policy]based on services actually detected by a daily site scan. - Branded via CSS variables — primary color, background, text, border, radius, font, layout (bar/box), position.
- Designed to stay compatible with LiteSpeed Cache, Cloudflare, and full-page caching (all visitors get the same cached HTML; banner state is client-side).
- Deployed via GitHub + Plugin Update Checker for centralized updates across all client sites.
Install
- Download the ZIP from the latest GitHub release or build locally:
zip -r gfw-consent.zip gfw-consent/. - In WordPress admin: Plugins → Add New → Upload Plugin.
- Activate.
- Drop the Plugin Update Checker library into
lib/plugin-update-checker/(see below). - Go to Consent in the admin sidebar and configure.
Plugin Update Checker setup
The main plugin file loads PUC v5 from lib/plugin-update-checker/plugin-update-checker.php. To enable centralized GitHub updates:
- Download Plugin Update Checker: https://github.com/YahnisElsts/plugin-update-checker
- Extract the
plugin-update-checker-5.xfolder into this plugin's/lib/directory and rename it toplugin-update-checker. - In
gfw-consent.php, update the GitHub URL to your repo. - (Optional) For a private repo, uncomment the
setAuthentication()line and supply a GitHub PAT. - Push a tagged release to GitHub. WP admin will show the update within ~12 hours or on manual "Check Again".
Shortcodes
| Shortcode | Purpose |
|---|---|
[gfw_consent_policy] |
Full cookie policy page. Place on /cookie-policy. |
[gfw_consent_preferences label="Cookie preferences"] |
Button / link to reopen the preferences modal. Place in footer. |
JavaScript API
For theme or custom code:
GFWConsentAPI.openPreferences(); // Opens the preferences modal
GFWConsentAPI.getState(); // Returns { id, c: [categories], v, t }
GFWConsentAPI.withdraw(); // Resets consent to "reject all"
Listen for consent changes:
document.addEventListener('gfw:consent', function (e) {
// e.detail = { id, c: ['analytics', ...], v, t }
});
Adding new services to the catalog
Services live in includes/class-gfw-consent-services.php. Each entry needs:
'service-slug' => array(
'name' => 'Display Name',
'vendor' => 'Vendor Inc.',
'category' => 'marketing', // essential | functional | analytics | marketing
'patterns' => array( 'cdn.example.com/tracker.js' ),
'cookies' => array( '_svc_*' ),
'privacy' => 'https://example.com/privacy',
'purpose' => 'One-sentence plain-English purpose.',
'retention' => 'Up to 1 year',
),
patterns are plain substrings matched case-insensitively against both `
Releases
9 releases. Each count is every asset in that release; expand a row for the breakdown.