AMP WP – Google AMP For WordPress changelog
By Pixelative, on WordPress.org since 2018. 700+ active installs.
55 tagged releases, newest first. Dates are when each release was tagged in SVN. Notes come from the plugin's readme, which may not list every release.
-
- Fixed * Fix: JSON-LD structured data now uses canonical (non-AMP) URLs for mainEntityOfPage, NewsArticle url, and author url instead of the AMP endpoint URLs that Google Search Console flagged as mismatched. * Fix: JSON-LD description no longer concatenates words when HTML tags are stripped (e.g. “thatpeople” is now “that people”). * Fix: Author object in JSON-LD now includes the url property pointing to the author archive page, satisfying Google’s structured data recommendation. * Fix: SearchAction urlTemplate in WebSite and WebPage schemas now uses the correct home_url('/?s={search_term_string}') format instead of the malformed double-path get_search_link() . '?s=...'. * Fix: Sanitizer now preserves amp-bind bracket attributes ([src], [hidden], [class], [text], etc.) on elements with tag rules, preventing them from being stripped during STEP 8 attribute filtering. * Fix: Added amp-state to the allowed protocol list for amp-list src, so src="amp-state:..." no longer triggers element removal. * Fix: Added hidden to the general attributes whitelist so the HTML5 hidden attribute is preserved on all elements during sanitization. * Fix: Social share links multi-select in Layout settings was double-escaping the selected attribute via esc_attr(), potentially preventing saved selections from being restored. Same bug fixed in General settings post types and taxonomies multi-selects. * Fix: submit_button() text argument was wrapped in esc_html__() across all settings tabs, causing double-escaping since submit_button() escapes internally. Replaced with __(). * Fix: 11 missing translation defaults for comment-related keys in amp_wp_translation_stds(), causing empty strings on the front-end when the Translation settings page was never saved. * Fix: Translation settings page was missing the sidebar header field and the WooCommerce translation section (now shown only when AMP WP WooCommerce is active). * Fix: Customizer class _x() call had the textdomain in the context parameter slot, resulting in an untranslated string. * Fix: Textarea fields for exclude URLs in General settings and GDPR consent message used wp_kses_post() instead of esc_textarea() inside <textarea> elements. * Fix: Theme name label in General settings used esc_attr() instead of esc_html() for text content inside a <label>.
- Improvements * CSS: Settings page header/footer bars now align with the sidebar menu item height (flexbox layout, matched padding, corrected button line-height).
- Refactored * Full WPCS/Intelephense cleanup of all 8 Settings admin templates (General, Layout, Social Links, Analytics, Translation, Notice Bar, GDPR, Third-Party Plugins, Premium Extensions): file docblocks moved before ABSPATH guards, defensive isset() defaults for all template variables, loose comparisons on toggle switches replaced with ! empty(), manual selected="selected" ternaries replaced with WordPress selected() helper, consistent esc_attr()/esc_html()/esc_textarea() usage. * Full WPCS cleanup of sanitizer-rules.php, tags-list.php, and class-amp-wp-content-sanitizer.php (82 errors + 25 warnings to 0/0). Added file-level docblocks, backfilled all @param/@return annotations, strict comparisons, strict in_array, refactored assignment-in-condition patterns, renamed underscore-prefixed private methods, replaced mt_rand with wp_rand. * WPCS cleanup of 6 Customizer control classes: file docblocks, PHPDoc annotations, hardcoded version strings replaced with AMP_WP_VERSION. * Replaced urlencode() with rawurlencode() in the Customizer class. * Renamed AMPWP_WOOCOMMERCE_VERSION constant to AMP_WP_WOOCOMMERCE_VERSION in the WooCommerce add-on for naming consistency with the plugin family.
-
- Security * Security: Added current_user_can( 'manage_options' ) capability check to the settings save dispatcher. Previously only nonce verification protected the save path. * Security: All settings values saved via filter_input_array( INPUT_POST ) are now sanitized through wp_kses_post() before storage across all 9 settings classes (General, Layout, Social Links, Analytics, Translation, Notice Bar, GDPR, Structured Data, Third-Party Plugins). Safe HTML (links, bold, emphasis) used in GDPR consent text and copyright fields is preserved; dangerous HTML (script, iframe, event handlers) is stripped. Previously raw POST values were stored directly. * Security: Fixed missing sanitize_text_field on the Google Analytics tracking ID before storage. * Security: Sanitized the AMP-Redirect-To response header in the consent submission AJAX handler with esc_url_raw() to prevent header injection via a crafted Referer. * Security: Added AMP CORS origin validation to the amp_consent_submission AJAX handler. The handler now verifies the Origin / AMP-Same-Origin header and __amp_source_origin parameter before responding, preventing cross-origin request forgery. Also adds the required Access-Control-Expose-Headers response header per the AMP CORS spec. * Security: Escaped OneSignal subscribe/unsubscribe button labels with esc_html(). The translation strings were echoed without escaping inside <button> elements on the public frontend. * Security: Sanitized direct $_GET and $_COOKIE access in the mobile auto-redirect skip logic with sanitize_text_field( wp_unslash() ). * Security: Added if ( ! defined( 'ABSPATH' ) ) exit; direct-access guard to all PHP files that were missing it (admin partials, public templates, class files, function files, index files). * Security: Switched social share count API calls from HTTP to HTTPS (Facebook, Pinterest, Reddit). Removed deprecated Twitter/newsharecounts and StumbleUpon endpoints. Removed sslverify => false from remote request args. Added esc_url_raw() on the URL parameter and (int) cast on returned counts.
- Fixed * Fix: System Status GET connectivity check was incorrectly evaluating $post_response instead of $get_response, causing the GET test to always mirror the POST result. * Fix: the content sanitizer stripped the AMP global attributes placeholder, fallback, and overflow from regular elements, turning amp-list / amp-iframe loading placeholders and error fallbacks into permanently visible static content (e.g. the WooCommerce AMP cart showed “Unable to load your cart” even after the cart loaded — see the amp-wp-woocommerce changelog). These attributes are now whitelisted alongside submit-success / submit-error. * Fix: the amp-list sanitizer rule predated several spec attributes and stripped them; items, single-item, max-items, binding, reset-on-refresh, and xssi-prefix are now allowed. Stripping items silently forced every amp-list onto the default items JSON key, breaking any list bound to a different key (e.g. the cart totals list reading items="totals"). * Fix: the content sanitizer removed the JSON payload (<script type="application/json">) inside <amp-state> elements – its script-removal pass only kept JSON scripts whose parent is amp-analytics, amp-geo, or amp-consent. Every amp-state therefore rendered empty, and any amp-bind interaction reading that state silently broke (e.g. the WooCommerce variable-product add-to-cart on AMP single pages – see the amp-wp-woocommerce changelog). amp-state is now included in the allowed-parent list for JSON scripts.
-
- Features * i18n: Community-driven translations are now documented and supported via translate.wordpress.org, local .po/.mo files, and the built-in Translation Panel. Updated the .pot file and added contributor instructions in the readme.
- Improvements * Compat: Added two compatibility action hooks inherited from other AMP plugins (ampforwp_after_header in the header template and amp_post_template_css in the custom-styles buffer). These are not part of the AMP WP public API; they allow third-party plugins that target the AMPforWP hook surface to inject content and CSS on AMP WP pages without forking core. * The plugin update notice on the Plugins page is now a branded, visually distinct card with a version badge, checkmark bullet list, and clear layout.
- Fixed * Fix: System Status “Get System Report” button produced an empty textarea. Rewrote the report generation: the plain-text report is now built server-side in PHP and passed to the frontend as a JS variable, replacing the fragile client-side jQuery DOM-parsing logic that scraped table cells. Also added tiptip-jquery-plugin as a script dependency and guarded both tipTip() calls with $.fn.tipTip checks so tooltip failure can never block other admin functionality.
-
- Features * New “Hide Title in Single” toggle in Settings > Layout > Single Post Page. When enabled, the post title (the H1 heading) is hidden on AMP single-post pages – handy when a long title takes up too much space on mobile. Off by default, so existing sites are unaffected; the title still appears in the browser tab and in JSON-LD structured data, so SEO is not impacted.
- Fixed * AMP-Validity: Added a CSS value sanitizer that rounds decimal rgb()/rgba() values to integers and strips attr() / type() (CSS Level 5) declarations. Resolves the “CSS syntax error in tag style amp-custom” validation error caused by WordPress 7.0 view-transitions CSS and Dart Sass compiled stylesheets.
- Improvements * Docs: Split the changelog so the readme stays within the WordPress.org 5,000-word limit. Recent releases remain here; the complete history now lives in changelog.txt (WordPress.org archive) and the GitHub Markdown mirror CHANGELOG.md. Changelog entries are standardised into the section order Features, Security, Fixed, Improvements, WordPress Compatibility (Compat), Refactored.
- Refactored * WPCS cleanup of class-amp-wp-layout.php: added the missing class docblock and terminated four section-marker comments. No behaviour change. * WPCS cleanup of the Layout settings admin view (amp-wp-admin-layout.php): added the missing blank line after the file docblock, supplied the amp-wp text domain on two untranslated option labels, and switched loose comparisons to strict – select dropdowns now use === against their string values while on/off toggles use ! empty() (avoids the int-vs-string trap where a saved 1 would not match '1' under ===). No behaviour change. * WPCS cleanup of the General settings admin view (amp-wp-admin-general.php): switched the two AMP URL Format dropdown comparisons (start-point / end-point) to strict ===, and defaulted the variables the view receives from its controller (null-coalescing to the controller’s own defaults) so the template also resolves cleanly under static analysis. No behaviour change. * WPCS cleanup of five Settings tab classes (general, premium-extensions, social-links, structured-data, third-party-plugins-support): added missing file/class docblocks, moved the ABSPATH guard below the file docblock where it had been inlined on the opening tag, and terminated inline/param comments. No behaviour change. * WPCS cleanup of the Translation settings class (class-amp-wp-translation.php): same docblock/guard/comment fixes, plus added the required translators: comments for the placeholder strings “Reply To %s” and “Page %1$s of %2$s” so the placeholders are documented for translators. No behaviour change. * WPCS cleanup of the Analytics settings class (class-amp-wp-analytics.php): added the missing class docblock. No behaviour change. * Docs: fixed malformed @param PHPDoc blocks on the amp_wp_settings_tab_menus (class-amp-wp-settings.php) and amp_wp_welcome_tab_menus (class-amp-wp-welcome.php) filters (invalid array (){ hash notation that broke static analysis) and corrected an @Since tag typo. No behaviour change. * Removed: deleted the orphaned, never-loaded duplicate class file class-amp-wp-system-status-override-function.php (it redeclared the active Amp_WP_System_Status class and still carried old WooCommerce-coupled code). Also finished WPCS cleanup of the active class-amp-wp-system-status.php: added the class docblock, reworded a comment, and dropped an unnecessary @ error-suppression on ini_get(). No behaviour change. * WPCS cleanup of the Help admin class (class-amp-wp-help.php): added the missing class docblock and reworded a comment flagged as commented-out code. No behaviour change. * WPCS cleanup of three Welcome-page tab classes (class-amp-wp-credits.php, class-amp-wp-features.php, class-amp-wp-getting-started.php): added the missing class docblock to each. No behaviour change.
-
- Fixed * AMP-Validity: Three-layer defense for the @view-transition validation error on WordPress 7.0 sites with View Transitions enabled, covering head <style> extraction plus input-layer and output-layer stripping.
-
- Fixed * AMP-Validity: Strip CSS at-rules not allowed in <style amp-custom> (@view-transition, @import, @charset, @namespace, @layer), including when nested inside @media or @supports. Resolves the @view-transition error added by WordPress 7.0 global styles. * Resolved six IDE diagnostics in the theme-functions library (split a void/echo helper, fixed an invalid component-method call, corrected several void-return assignments). No behaviour change.
- Refactored * WPCS cleanup of the core, formatting, utility, and ad function files. No behaviour change.
-
- Fixed * Amp_WP_Html_Util::set_outer_HTML() now replaces the target element in place instead of wiping surrounding markup. Fixes SoundCloud iframe embeds destroying sibling elements.
- WordPress Compatibility (Compat) * Verified and declared WordPress 7.0 compatibility. Tested up to WordPress 7.0.
- Refactored * PHPCS cleanup of the image, Instagram, Playbuzz, iframe, and carousel components plus the theme-functions library. No behaviour change.
-
- Features * AdSense Auto Ads: AMP WP now emits the <amp-auto-ads type="adsense"> body element automatically when “Google Auto Ads” is enabled, completing turnkey Auto Ads support. The publisher ID is auto-resolved from Google Site Kit, or supplied via the new amp_wp_adsense_publisher_id filter. New public functions amp_wp_get_adsense_publisher_id() and amp_wp_render_auto_ads_element().
- Fixed * AMP-Validity: Closes the “extension amp-auto-ads is unused” validator error on sites running Google Site Kit.
-
- Features * New native “Google Auto Ads” toggle on Settings > General. Enabling it enqueues the amp-auto-ads runtime loader via the canonical AMP component pipeline, so the script no longer needs to be pasted into the Customizer head-code field. Any manually pasted loader is auto-cleaned on save.
- Fixed * AMP-Validity: The GDPR consent banner’s EU country list inside <amp-geo> was emitted as a corrupted HTML-encoded string, causing the AMP runtime to reject the config and silently disable the geo-gated banner. It is now emitted as valid JSON.
- Refactored * WPCS sweep of the Tez theme directory (37 files, 49 errors and 31 warnings down to zero) and removal of a dormant placement-manager file from core. No behaviour change.
-
- Features * New “Premium Extensions” tab (hidden until at least one AMP WP family add-on is active) as a central home for add-on settings. * New public APIs amp_wp_register_premium_extension() and amp_wp_register_template_path() so family add-ons can self-register and ship their own AMP templates. * New extension hook amp_wp_layout_setting_after_show_comments for add-ons to extend the comment settings block.
- Security * Comprehensive WPCS security sweep across the whole plugin: output escaping on every flagged echo/printf, guarded and sanitized superglobal reads, and modern phpcs:ignore annotations. The escaping, nonce, and sanitize sniffs now report zero errors (down from 311). No behaviour change.
- Fixed * /favicon.ico and other root-level static-file requests on mobile no longer redirect to /<file>/amp and 404. * Search-engine crawlers are no longer caught by the mobile auto-redirect to AMP, fixing “Redirect error” rows in Google Search Console. * Pagination on AMP archives now works for every URL shape (e.g. /shop/amp/page/2/). * The Premium Extensions tab icon now renders (was an empty glyph).
- Improvements * Inline help text added across the Structured Data, GDPR, Notice Bar, Layout, General, and 3rd Party Plugins (OneSignal) settings tabs.
-
- Fixed * Mobile browsers no longer get stuck in a “too many redirects” loop on AMP URLs after AMP-exclusion settings change. Plugin redirects now use 302 plus no-cache headers, with a one-shot Clear-Site-Data to recover clients holding a stale 301. * amp-state elements are no longer stripped when the AMP WP Comments add-on is active. * Per-comment Reply links now appear on threaded AMP comment lists (WordPress 6.8), with the correct “Reply” label. * AFS Analytics configuration JSON was malformed and silently disabled analytics; now fixed.
- Improvements * WPCS compliance for the redirect-router and public classes; same-origin redirects switched to wp_safe_redirect(). No public-API change. * New tools/test-redirects.sh curl smoke harness for verifying redirect behaviour before release.
-
- Fixed * The header and sidebar logo was silently stripped on every AMP page since v1.7.2 (a PHPCS escaping pass removed <amp-img> / <amp-anim>). A dedicated sanitizer now preserves the logo markup. * Notice Bar and GDPR Compliance no longer fail to appear due to an integer-vs-string comparison; several related Notice Bar and GDPR save/validation bugs also fixed.
- Improvements * The AMP WP editor meta box rebuilt with a professional toggle-switch UI, pinned to the top of the sidebar.
-
- Fixed * Yoast SEO (v14+): meta description, Open Graph, and Twitter Card tags were silently missing on AMP pages; duplicate title/robots tags and a 300-second front-page timeout also resolved. * All In One SEO Pack (v4+): missing meta/OG/Twitter tags and homepage title sync fixed. * WP-Optimize and WP Fastest Cache: HTML/CSS minification and related features that ran unchecked on AMP pages are now correctly disabled. * OneSignal Web Push: the subscribe widget was never rendered on AMP pages; now fixed. * wpForo 3.x: AMP pages were incorrectly served on forum URLs; detection now uses WPFORO_VERSION. * JSON-LD structured data: schema type validated against an allow-list, ISO 8601 dates, integer interaction counts, and a guaranteed image fallback.
- Improvements * Removed dead compatibility blocks for Multi Rating and verified Snip Rich Snippets compatibility.
-
- Fixed * Google Analytics: GA4 (G-XXXXXXXX) IDs now use the correct amp-analytics tag, fixing the post-migration console warning. * JSON-LD: 11 Schema.org / Google Rich Results compliance issues resolved. * AdSense Auto Ads: corrected head-injection order so Auto Ads fire correctly.
- Improvements * Upgraded Font Awesome from 4.7.0 to 6.7.2, eliminating console font warnings; existing icon classes are unchanged. * WPCS compliance in the template-functions and HTML-util files. No behaviour change.
-
- Fixed * Admin Select2 CSS now scoped to AMP WP, preventing conflicts with ACF and other Select2-shipping plugins. * The “Add Comment” button is no longer hidden on posts with zero comments. * WP Rocket redirect loop on AMP-excluded URLs resolved; excluded URLs are pushed into WP Rocket’s bypass list. * Polylang subdirectory language URLs (e.g. /uk/category/post/amp/) no longer 404. * Fixed an “Undefined array key” nonce warning in the settings save handler.
- Improvements * Add-ons tab card layout refined; plugin-compatibility class docblocks rewritten. * Removed compatibility for the closed WP Speed Grades Lite plugin.
-
- Features * Add-ons tab now shows installed vs latest version for each premium add-on, with context-aware Download/Update buttons. Latest versions are fetched from a public GitHub repo and cached for 12 hours; ?amp_refresh_versions=1 forces a refresh. * Full Help & Documentation page replacing the placeholder.
- Fixed * Activation redirect switched to wp_safe_redirect() plus exit. * amp_wp_version_check_using_wpapi() guarded against duplicate inclusion. * Fixed an undefined $page warning in the admin header.
- For the complete version history (1.6.0 and all earlier releases, in full detail), see the changelog.txt file included with the plugin.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.
-
No notes for this release in the current readme.