Skip to content

Instantly share code, notes, and snippets.

@adamsilverstein
adamsilverstein / wp-rocket-site-kit-compat.php
Last active March 18, 2022 06:12
Improve compatibility between Site Kit and WP Rocket
<?php
/**
* WP Rocket compatibility for Site Kit.
*
* @wordpress-plugin
* Plugin Name: SiteKit WP Rocket Compatibility
* Description: Improve compatibility between Site Kit and WP Rocket.
* Plugin URI:
* Version: 1.0.0
* Author: Adam Silverstein, Google
@felixarntz
felixarntz / google-site-kit-anonymize-ips.php
Last active August 25, 2021 17:02
WordPress mini plugin as an extension to Site Kit that ensures the inserted Google Analytics snippet anonymizes IP addresses.
<?php
/**
* Site Kit by Google Anonymize IPs plugin file.
*
* @package Google\Site_Kit_Anomyize_IPs
* @author Felix Arntz, Google
* @license GPL-2.0-or-later
* @copyright 2019 Google Inc.
*
* @wordpress-plugin
@westonruter
westonruter / amp-reader-nav-menu.php
Last active May 9, 2022 16:35
Basic plugin which adds a nav menu to Reader mode templates in the AMP plugin. When in Reader mode, upon activation a new “AMP Reader Sidebar” nav menu location is available for assigning the desired nav menu. Temporary until closed: https://github.com/ampproject/amp-wp/issues/2044
<?php
/**
* Plugin Name: AMP Reader Nav Menu
*
* @package AMP_Reader_Nav_Menu
* @author Weston Ruter, Google
* @license GPL-2.0-or-later
* @copyright 2019 Google Inc.
*
* @wordpress-plugin
<?php
/**
* AMP-To-AMP plugin initialization file.
*
* @package AMP_To_AMP
* @author Weston Ruter, Google
* @link https://gist.github.com/westonruter/f9ee9ea717d52471bae092879e3d52b0
* @license GPL-2.0-or-later
* @copyright 2019 Google Inc.
*
<?php
/**
* Plugin Name: AMP Schema.org Meta Image Content Fallback
* Description: Promote content image as Schema.org image when no featured image is supplied.
* Plugin URI: https://gist.github.com/westonruter/7358d6669e09cfa15a99021204208a67
* Author: Weston Ruter
* Author URI: https://weston.ruter.net/
* Gist Plugin URI: https://gist.github.com/westonruter/7358d6669e09cfa15a99021204208a67
*/
@CannonballSkippy
CannonballSkippy / test.html
Created May 17, 2017 21:33
Basic markup test content for typography
<h1>Testing display of HTML elements</h1>
<h2>This is 2nd level heading</h2>
<p>This is a test paragraph.</p>
<h3>This is 3rd level heading</h3>
<p>This is a test paragraph.</p>
<h4>This is 4th level heading</h4>
<p>This is a test paragraph.</p>
<h5>This is 5th level heading</h5>
<p>This is a test paragraph.</p>