Skip to content

Instantly share code, notes, and snippets.

@thefuxia
thefuxia / all-actions-list.php
Created March 5, 2012 16:36
Plugin All Actions List
<?php # -*- coding: utf-8 -*-
/*
Plugin Name: All Actions List
Description: Lists all actions run during one request.
Version: 1.0
Required: 3.1
Author: Thomas Scholz
Author URI: http://toscho.de
License: GPL
*/
@thefuxia
thefuxia / plugin-class-demo.php
Last active October 4, 2023 00:10
Plugin Class Demo
<?php # -*- coding: utf-8 -*-
/**
* Plugin Name: Plugin Class Demo
* Description: How I am using the base class in plugins.
* Plugin URI:
* Version: 2012.09.29
* Author: Fuxia Scholz
* License: GPL
* Text Domain: plugin_unique_name
* Domain Path: /languages
@thefuxia
thefuxia / t5-highlight.php
Created June 1, 2017 08:42
WordPress plugin for highlight.js
<?php # -*- coding: utf-8 -*-
/**
* Plugin Name: T5 Highlight
* Description: Use highlight.js on front end. Mark code with <code>&lt;pre class="language-php"&gt;&lt;code&gt;your code&lt;/code&gt;&lt;/pre&gt;</code>
* Version: 31.10.14
* Required: 4.0
* Author: Thomas Scholz
* Author URI: http://toscho.de
* License: MIT
* License URI: http://www.opensource.org/licenses/mit-license.php
<?php # -*- coding: utf-8 -*-
/**
* Create a nav menu with very basic markup.
*
* @author Thomas Scholz http://toscho.de
* @version 1.0
*/
class T5_Nav_Menu_Walker_Simple extends Walker_Nav_Menu
{
/**
@thefuxia
thefuxia / replace-content-with-excerpt.php
Last active March 17, 2022 00:03
Replace full content with excerpt
<?php # -*- coding: utf-8 -*-
/**
* Plugin Name: Replace full content with excerpt
* Description: Replaces the full content on post listings with an excerpt
* Version: 2012.06.22
* Author: Fuxia Scholz
* License: MIT
* License URI: http://www.opensource.org/licenses/mit-license.php
*/
@thefuxia
thefuxia / disable-wptexturize.php
Last active February 3, 2022 15:49
Disable Wptexturize
<?php
/*
Plugin Name: Disable Wptexturize
Description: Removes most calls to this incredible slow function.
Version: 1.0
Author: Thomas Scholz
Author URI: http://toscho.de
License: GPL
*/
@thefuxia
thefuxia / list-comment-filters.php
Last active January 15, 2022 18:53
WordPress Plugin: List Comment Filters
<?php
/*
Plugin Name: List Comment Filters
Description: List all comment filters on wp_footer
Version: 1.1
Author: Fuxia Scholz
License: GPL v2
*/
add_action( 'wp_footer', 'list_comment_filters' );
@thefuxia
thefuxia / t5-custom-logout-url.php
Created December 14, 2012 20:49
T5 Custom Log-out URL Create a custom log-out URL in WordPress.
<?php
/**
* Plugin Name: T5 Custom Log-out URL
* Description: Create a custom log-out URL.
* Plugin URI: http://wordpress.stackexchange.com/questions/76161/masking-logout-url
* Version: 2012.12.14
* Author: Thomas Scholz
* Author URI: http://toscho.de
* Licence: MIT
* License URI: http://opensource.org/licenses/MIT
@thefuxia
thefuxia / hide-dead-menu-metaboxes.php
Last active September 17, 2021 15:25
T5 Hide dead menu metaboxesWordPress Plugin to improve the menu management screen.
<?php
/**
* Plugin Name: T5 Hide dead menu metaboxes
* Description: Do not show menu metaboxes when no nav menu exists.
* Plugin URI: https://gist.github.com/thefuxia/4432959
* Version: 2013.01.02
* Author: Fuxia Scholz
* Author URI: https://fuxia.me
* Licence: MIT
* License URI: http://opensource.org/licenses/MIT
@thefuxia
thefuxia / basic_meta_box.php
Last active September 2, 2021 16:22
WordPress meta box example
<?php # -*- coding: utf-8 -*-
declare( encoding = 'UTF-8' );
/**
* Plugin Name: Basic Meta Box
* Description: Create a simple meta box. Demo plugin.
* Version: 2012.02.05
* Required: 3.3
* Author: Fuxia Scholz
* Author URI: https://fuxia.me
* License: GPL