Skip to content

Instantly share code, notes, and snippets.

@kovshenin
Created November 15, 2012 05:15
Show Gist options
  • Save kovshenin/4076784 to your computer and use it in GitHub Desktop.
Save kovshenin/4076784 to your computer and use it in GitHub Desktop.
<?php
/**
* Plugin Name: My Plugin 21689
*/
class My_Plugin_Test_21689 {
function __construct() {
add_action( 'init', array( $this, 'init' ) );
}
function init() {
add_shortcode( 'test21689', array( $this, 'shortcode_callback' ) );
echo apply_filters( 'the_content', "[test21689]\n\nsome content\n\n[/test21689]" );
die();
}
function shortcode_callback( $args, $content ) {
return $content;
}
}
new My_Plugin_Test_21689;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment