I retired my @glueckpress GitHub account. My active account is @casparhubinger.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: Press This | Default Terms | |
* Description: Sets a custom default post format and category for post drafts saved via Press This. | |
* Version: 0.0.2 | |
* Author: Caspar Hübinger | |
* Author URI: http://glueckpress.com/ | |
* License: GNU General Public License v2 or later | |
* License URI: http://www.gnu.org/licenses/gpl-2.0.html | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Block: Map | |
* Description: Generates a static map image via Google Static Maps API. | |
* | |
* @see https://staticmapmaker.com/google/ | |
* @see https://github.com/getblocklab/block-lab | |
* ---------------------------------------- | |
* Block config: | |
* ---------------------------------------- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: IndieWeb | Customisations | |
* Description: Customises relme list of the IndieWeb plugin. | |
* Version: 2019.01 | |
* Author: Caspar Hübinger | |
* Author URI: http://glueckpress.com/ | |
* License: GNU General Public License v2 or later | |
* License URI: http://www.gnu.org/licenses/gpl-2.0.html | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Plugin Name: Comment without IP | |
* Plugin URI: https://gist.github.com/glueckpress/74710e5954f12f4da164f810b7976529 | |
* Description: Removes a commenter’s IP address from new comments. | |
* Version: 0.0.1 | |
* Author: Caspar Hübinger | |
* Author URI: https://profiles.wordpress.org/glueckpress | |
* License: GNU General Public License v3 | |
* License URI: http://www.gnu.org/licenses/gpl-3.0.html |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Zero browser caching for PDF files. | |
*/ | |
add_filter( 'rocket_htaccess_mod_expires', function ( $rules ) { | |
$rules .= '# Expires headers for PDF' . PHP_EOL; | |
$rules .= '<IfModule mod_expires.c>' . PHP_EOL; | |
$rules .= 'ExpiresByType application/pdf "access plus 0 seconds"' . PHP_EOL; | |
$rules .= '</IfModule>' . PHP_EOL . PHP_EOL; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* WP Rocket: | |
* 1. Customise order of minification and defer operations. | |
* 2. Exclude file from defer JS only (still minified). | |
* | |
* Tested rudimentary with WP Rocket 2.11.7 and 3.0.x. | |
* Test before using this in production! | |
*/ | |
add_action( 'wp_rocket_loaded', function () { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
/** | |
* Takes a WordPress post ID and checks if the post has a more link. | |
* | |
* @author Caspar Hübinger | |
* @uses get_extended() | |
* @link https://developer.wordpress.org/reference/functions/get_extended/ | |
* | |
* @param int $post_id Post ID | |
* @return boolean True if text exists before more tag, else false |
NewerOlder