View ImageOverride
<?php | |
/* | |
Plugin Name: Image Override | |
Plugin URI: http://www.billerickson.net | |
Description: Allows you to override image sizes | |
Version: 1.0 | |
Author: Bill Erickson | |
Author URI: http://www.billerickson.net | |
License: GPLv2 | |
*/ |
View display_posts_shortcode_output.php
<?php | |
/** | |
* Add Facebook Button to Display Posts Shortcode plugin | |
* @author Bill Erickson | |
* @link http://wordpress.org/extend/plugins/display-posts-shortcode/ | |
* @link http://wordpress.org/support/topic/facebook-likeshare-button-at-the-end-of-excerpt | |
* | |
* @param $output string, the original markup for an individual post | |
* @param $atts array, all the attributes passed to the shortcode | |
* @param $image string, the image part of the output |
View gist:1179950
<?php | |
/** | |
* Shorten excerpt in display posts shortcode | |
* @author Bill Erickson | |
* @link http://wordpress.org/extend/plugins/display-posts-shortcode/ | |
* @link http://www.billerickson.net/shortcode-to-display-posts/comment-page-1/#comment-4508 | |
* | |
* @param $output string, the original markup for an individual post | |
* @param $atts array, all the attributes passed to the shortcode |
View gist:1193447
<?php | |
/** | |
* Template Redirect | |
* Use archive-event.php for all events and 'event-category' taxonomy archives. | |
* Use archive-business.php for all businesses and 'business-category' taxonomy archives. | |
* | |
*/ | |
function be_template_redirect( $template ) { | |
if ( is_tax( 'event-category' ) ) $template = get_query_template( 'archive-event' ); | |
if ( is_tax( 'business-category' ) ) $template = get_query_template( 'archive-business' ); |
View gist:1196287
<?php | |
/** | |
* Remove Metaboxes | |
* This removes unused or unneeded metaboxes from Genesis > Theme Settings. | |
* See /genesis/lib/admin/theme-settings for all metaboxes. | |
* | |
* @author Bill Erickson | |
* @link http://www.billerickson.net/code/remove-metaboxes-from-genesis-theme-settings/ | |
*/ | |
View gist:1204283
<?php | |
// Changes to metabox array, new field 'show_on' | |
$meta_boxes[] = array( | |
'id' => 'blog-options', | |
'title' => 'Blog Options', | |
'pages' => array('page'), | |
'show_on' => array( 'key' => 'id', 'value' => array( 12 ) ), | |
'context' => 'normal', | |
'priority' => 'low', |
View gist:1207505
<?php | |
/** | |
* functions.php | |
* | |
*/ | |
// Use single template file for Design Gallery archive and Taxonomy | |
add_filter('template_include', 'be_design_gallery_template', 1, 1); |
View gist:1209601
<?php | |
/** | |
* Add custom fields to Display Posts Shortcode | |
* @author Bill Erickson | |
* @link http://wordpress.org/extend/plugins/display-posts-shortcode/ | |
* @link http://www.billerickson.net/shortcode-to-display-posts/comment-page-1/#comment-4565 | |
* | |
* @param $output string, the original markup for an individual post | |
* @param $atts array, all the attributes passed to the shortcode | |
* @param $image string, the image part of the output |
View gist:1212577
<?php | |
/** | |
* Change 'products' posts per page on archive | |
* This is the long version that explains everything | |
*/ | |
function be_modify_products_query_long ( $query ) { | |
// Check to make sure we're modifying the main query | |
global $wp_the_query; | |
if( $wp_the_query !== $query ) |
View gist:1222768
Index: cms-page-order.php | |
=================================================================== | |
--- cms-page-order.php (revision 439171) | |
+++ cms-page-order.php (working copy) | |
@@ -36,8 +36,11 @@ | |
/** Setup Page, Styles and Scripts */ | |
function cmspo_admin_menu() { | |
load_plugin_textdomain( 'cms-page-order', false, '/cms-page-order/locale/'); | |
- $page = add_submenu_page( 'edit.php?post_type=page', __( 'Page Order', 'cms-page-order' ), __( 'Page Order', 'cms-page-order' ), 'edit_pages', 'order', 'cmspo_menu_order_page' ); | |
- add_action( 'admin_print_styles-' . $page, 'cmspo_print_styles' ); |
OlderNewer