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 | |
// Register widget area | |
genesis_register_sidebar( array( | |
'id' => 'sample', | |
'name' => __( 'Sample', 'your-child-theme-text-domain' ), | |
'description' => __( 'This is the sample widget area description.', 'your-child-theme-text-domain' ), | |
) ); |
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 | |
// Add new featured image sizes | |
add_image_size( 'home-bottom', 150, 100, true ); | |
add_image_size( 'home-top', 400, 200, true ); |
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 | |
add_filter( 'template_include', 'ja_template_include' ); | |
/** | |
* Apply a template to all subcategories of a certain parent category. | |
* | |
* @author Rogier Borst | |
* @author Gary Jones | |
* @author Jared Atchison | |
* | |
* @link https://gist.github.com/gists/2787095 Current version |
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 | |
add_action( 'template_redirect', 'kkf_single_search_redirect' ); | |
/** | |
* If only one search result match, automatically redirect to that result. | |
* | |
* @author Michael Bishop | |
* @link https://gist.github.com/2437076 | |
* | |
* @global WP_Query $wp_query Query object. |
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 | |
/** | |
* Create the Live Toolbar. | |
* | |
* @since 1.0.0 | |
*/ | |
function radio_live_toolbar() { |
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 | |
/** | |
* Possibly amend the loop. | |
* | |
* Specify the conditions under which the grid loop should be used. | |
* | |
* @author Bill Erickson | |
* @author Gary Jones | |
* @link http://code.garyjones.co.uk/genesis-grid-loop-advanced/ |
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 | |
add_filter( 'genesis_nav_items', 'sws_social_icons', 10, 2 ); | |
add_filter( 'wp_nav_menu_items', 'sws_social_icons', 10, 2 ); | |
/** | |
* Adds a widget area before primary menu items. | |
* | |
* @author Bill Erickson | |
* @author Gary Jones | |
* @link https://gist.github.com/gists/1799174 |
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 | |
/** | |
* Possibly amend the loop. | |
* | |
* Specify the conditions under which the grid loop should be used. | |
* | |
* @author Bill Erickson | |
* @author Gary Jones | |
* @link http://code.garyjones.co.uk/genesis-grid-loop-advanced/ |
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 | |
add_action( 'pre_get_posts', 'be_sort_articles_category' ); | |
/** | |
* Sort 'articles' category by name | |
* | |
* @author Bill Erickson | |
* @link http://www.billerickson.net/customize-the-wordpress-query/ | |
* @param object $query data | |
* |
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 | |
add_action( 'init', 'be_initialize_meta_boxes' ); | |
/** | |
* Initialize the metabox code library. | |
* | |
* Since this code might be in the theme and multiple plugins, | |
* see if it exists already before initializing it. | |
* | |
*/ |