This file contains hidden or 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 | |
| // Event taxonomies | |
| add_action( 'init', function() { | |
| $labels = array( | |
| 'name' => _x( 'Terms', 'taxonomy general name' ), | |
| 'singular_name' => _x( 'Term', 'taxonomy singular name' ), | |
| ); | |
| register_taxonomy( 'taxonomy_name', array( 'post' ), array( | |
| 'hierarchical' => false, |
This file contains hidden or 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 defined('ABSPATH') or die(); | |
| /* | |
| * Plugin Name: Bad Matt | |
| * Plugin URI: https://gschoppe.com | |
| * Description: A protest plugin that removes (or replaces via filter) the Automattic-owned woocommerce stripe gateway partner id. | |
| * Version: 1.0.0 | |
| * Requires at least: 4.0 | |
| * Requires PHP: 7.2 | |
| * Author: Greg Schoppe | |
| * Author URI: https://gschoppe.com/ |
This file contains hidden or 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 if( ! defined( 'ABSPATH' ) ) { die(); } | |
| /** | |
| * Plugin Name: Disable Attachment Pages | |
| * Plugin URI: https://gschoppe.com/wordpress/disable-attachment-pages | |
| * Description: Completely disable attachment pages the right way. No forced redirects or 404s, no reserved slugs. | |
| * Author: Greg Schoppe | |
| * Author URI: https://gschoppe.com/ | |
| * Version: 1.0.0 | |
| **/ |
This file contains hidden or 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 if( !defined( 'ABSPATH' ) ) { die(); } // Include in all php files, to prevent direct execution | |
| /** | |
| * Class Name : WP Persistent Notices | |
| * Description : Implements a Standardized messaging system that allows admin messages to be passed across page redirects. | |
| * Class URI : http://gschoppe.com/wordpress/pass-wordpress-admin-notices-across-page-redirects/ | |
| * Version : 1.0.0 | |
| * Author : Greg Schoppe | |
| * Author URI : http://gschoppe.com | |
| * License: GPL-2.0+ | |
| * License URI: http://www.gnu.org/licenses/gpl-2.0.txt |
This file contains hidden or 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
| function CropInterface(el, w, h, resolutionMultiple) { | |
| // handle parameters | |
| this.el = el; | |
| if (!w) { w = 100; } | |
| this.w = w; | |
| if (!h) { h = 100; } | |
| this.h = h; | |
| this.r = w / h; | |
| if (!resolutionMultiple) { resolutionMultiple = 1; } | |
| this.resolutionMultiple = resolutionMultiple; |
This file contains hidden or 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
| function ImageScaler(canvas, focus, zoom) { | |
| if (canvas) { | |
| this.canvas = canvas; | |
| } else { | |
| this.canvas = document.createElement("CANVAS"); | |
| } | |
| if (focus) { | |
| this.focus = focus; | |
| } else { | |
| this.focus = {x:.5,y:.5}; |
This file contains hidden or 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
| function IntervalManager() { | |
| this.intervals = []; | |
| // Public | |
| this.setInterval = function(callback, interval, name) { | |
| if (!name) { | |
| name = "" + Date.now() + "|" + Math.random(); | |
| } | |
| var newInterval = { | |
| 'name': name, |
This file contains hidden or 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
| function DB(projectID) { | |
| this.projectID = projectID; | |
| this.types = { | |
| 'INT64' : "INT64", | |
| 'NUMERIC' : "NUMERIC", | |
| 'BIGNUMERIC': "BIGNUMERIC", | |
| 'FLOAT64' : "FLOAT64", | |
| 'BOOL' : "BOOL", | |
| 'STRING' : "STRING", |
This file contains hidden or 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 | |
| if( !empty($_GET['request']) ) { | |
| $current_version = ""; | |
| $url = "https://api.wordpress.org/core/version-check/1.7/"; | |
| $curl = curl_init(); | |
| curl_setopt_array($curl, array( | |
| CURLOPT_RETURNTRANSFER => 1, | |
| CURLOPT_URL => $url | |
| )); | |
| $result = curl_exec($curl); |
This file contains hidden or 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
| // moved to https://wordpress.org/plugins/classic-editor-addon/ |
NewerOlder