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
jQuery(document).ready(function($) { | |
$("body").backstretch([BackStretchImg.src],{duration:3000,fade:750}); | |
}); |
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 | |
add_action( 'genesis_loop', 'cd_custom_taxonomy_archives' ); | |
function cd_custom_taxonomy_archives() { | |
//print the page title | |
the_title('<h1 class="entry-title">', '</h1>'); | |
// Code sample modified from example on http://wordpress.mfields.org/plugins/taxonomy-images/ | |
// This filter pulls similar results to get_terms(), except it also includes an image reference | |
$terms = apply_filters( 'taxonomy-images-get-terms', '', array('taxonomy' =>'your-tax-name') ); |
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
// Remove comments from posts | |
remove_action( 'genesis_after_post', 'genesis_get_comments_template' ); | |
// Add comments back in if conditions are met | |
add_action( 'genesis_after_post', 'cd_conditional_comments' ); | |
function cd_conditional_comments() { | |
// Conditional Reference http://codex.wordpress.org/Function_Reference/get_the_author | |
if ('Author Display Name' == get_the_author() ) { | |
genesis_get_comments_template(); |
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
// Get rid of WP-Views excess code in header | |
add_action( 'init', 'typeviews_cleanup' ); | |
function typeviews_cleanup() { | |
if ( !is_admin() ) { | |
global $WP_Views; | |
remove_action('wp_print_styles', array($WP_Views, 'add_render_css')); | |
remove_action('wp_head', 'wpv_add_front_end_js'); | |
wp_dequeue_style( 'views-pagination-style' ); |
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 | |
/** | |
* Template Name: Testimonial Archives | |
* Description: Used as a page template to show page contents, followed by a loop through a CPT archive | |
*/ | |
remove_action ('genesis_loop', 'genesis_do_loop'); // Remove the standard loop | |
add_action( 'genesis_loop', 'custom_do_grid_loop' ); // Add custom loop |
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 | |
/** | |
* Template Name: Testimonial Archives | |
* Description: Used as a page template to show page contents, followed by a loop through a CPT archive | |
*/ | |
remove_action ('genesis_loop', 'genesis_do_loop'); // Remove the standard loop | |
add_action( 'genesis_loop', 'custom_do_loop' ); // Add custom loop |
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
<div class="archive-page"> | |
<h2 id="pages">Pages</h2> | |
<ul> | |
<?php | |
// Add pages you'd like to exclude in the exclude here | |
wp_list_pages( | |
array( | |
'exclude' => '', | |
'title_li' => '', | |
) |
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
remove_action( 'genesis_loop', 'genesis_404' ); // Remove the default Genesis 404 content | |
add_action( 'genesis_loop', 'cd_custom_404' ); // Add function for custom 404 content | |
function cd_custom_404() { | |
if ( is_404() ) { | |
get_template_part('/partials/sitemap'); // Plop in our customized sitemap code | |
} | |
} |
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 | |
add_action( 'init', 'cd_register_shortcode' ); | |
/** | |
* Register shortcode with the theme | |
*/ | |
function cd_register_shortcode() { | |
add_shortcode( '404-search', 'cd_search_shortcode' ); | |
} |
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
/** Register widget areas */ | |
genesis_register_sidebar( array( | |
'id' => 'cta-1', | |
'name' => __( 'Call to Action', 'mp' ), | |
'description' => __( 'This is the call to action section.', 'mp' ), | |
) ); | |
/** Add CTA widget support for site. If widget not active, don't display */ |