This file contains 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
// Load Font Awesome | |
add_action( 'wp_enqueue_scripts', 'enqueue_font_awesome' ); | |
function enqueue_font_awesome() { | |
wp_enqueue_style( 'font-awesome', '//maxcdn.bootstrapcdn.com/font-awesome/latest/css/font-awesome.min.css' ); | |
} |
This file contains 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
add_shortcode( 'portfolio_terms', 'custom_portfolio_terms_shortcode' ); | |
/** | |
* Produces the linked post taxonomy terms list. | |
* | |
* Supported shortcode attributes are: | |
* after (output after link, default is empty string), | |
* before (output before link, default is 'Tagged With: '), | |
* sep (separator string between tags, default is ', '), | |
* taxonomy (name of the taxonomy, default is 'category'). | |
* |
This file contains 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 | |
/** | |
* Genesis Sample. | |
* | |
* This file adds functions to the Genesis Sample Theme. | |
* | |
* @package Genesis Sample | |
* @author StudioPress | |
* @license GPL-2.0+ | |
* @link http://www.studiopress.com/ |
This file contains 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
//* Add support for 3-column footer widgets | |
add_theme_support( 'genesis-footer-widgets', 3 ); |
This file contains 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 | |
//* Do NOT include the opening php tag | |
add_action( 'genesis_before', 'sk_replace_menu_in_primary' ); | |
/** | |
* Conditionally replace Custom Menu in Primary Navigation. | |
* | |
* @author Sridhar Katakam | |
* @link http://sridharkatakam.com/conditionally-replace-navigation-menu-genesis/ | |
*/ |
This file contains 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
//* Move Post Title and Post Info from inside Entry Header to Entry Content on Posts page | |
add_action( 'genesis_before_entry', 'reposition_entry_header' ); | |
function reposition_entry_header() { | |
if ( is_home() ) { | |
remove_action( 'genesis_entry_header', 'genesis_entry_header_markup_open', 5 ); | |
remove_action( 'genesis_entry_header', 'genesis_do_post_title' ); | |
remove_action( 'genesis_entry_header', 'genesis_post_info', 12 ); | |
remove_action( 'genesis_entry_header', 'genesis_entry_header_markup_close', 15 ); |
This file contains 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
genesis_register_sidebar( array( | |
'id' => 'nav-social-menu', | |
'name' => __( 'Nav Social Menu', 'your-theme-slug' ), | |
'description' => __( 'This is the nav social menu section.', 'your-theme-slug' ), | |
) ); | |
add_filter( 'genesis_nav_items', 'sws_social_icons', 10, 2 ); | |
add_filter( 'wp_nav_menu_items', 'sws_social_icons', 10, 2 ); | |
function sws_social_icons($menu, $args) { |
This file contains 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
//* Make Font Awesome available | |
add_action( 'wp_enqueue_scripts', 'enqueue_font_awesome' ); | |
function enqueue_font_awesome() { | |
wp_enqueue_style( 'font-awesome', '//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css' ); | |
} | |
/** | |
* Place a cart icon with number of items and total cost in the menu bar. |
This file contains 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 | |
/** | |
* This file displays Listings that are available for Rent. | |
* | |
*/ | |
add_filter( 'body_class', 'sk_body_class' ); | |
/** | |
* Adds a css class to the body element | |
* |
This file contains 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
// * Relocate titles on Page, Post and other single pages | |
add_action( 'genesis_after_header','relocate_entry_title_singular' ); | |
function relocate_entry_title_singular() { | |
if ( ! is_singular() ) | |
return; | |
echo '<div class="entry-header-wrapper"><div class="wrap">'; | |
genesis_do_post_title(); | |
genesis_post_info(); | |
echo '</div></div>'; |