Last active
August 18, 2016 08:34
-
-
Save robneu/5496621 to your computer and use it in GitHub Desktop.
Testimonials by Woo - Archive Template for 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
<?php | |
/** | |
* The custom testimonials post type archive template | |
* | |
* @since 1.0.0 | |
* | |
* @author FAT Media <[email protected]> | |
* @package Genesis | |
* | |
* @copyright Copyright (c) 2012, FAT Media | |
* @license http://opensource.org/licenses/gpl-2.0.php GNU Public License | |
*/ | |
/** Force full width content layout */ | |
add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_full_width_content' ); | |
/** | |
* Displays a custom header. | |
* | |
* @since 1.0.0 | |
*/ | |
add_action('genesis_after_header', 'bigfat_testimonial_header'); | |
function bigfat_testimonial_header() { | |
$testimonial_title = 'Our Clients Say We\'re Awesome'; | |
$testimonial_subtitle = 'Probably Because We Are'; | |
echo '<div class="services-title">'; | |
echo '<h1>' . esc_html( $testimonial_title ) . '<span> ' . esc_html( $testimonial_subtitle ) . ' </span></h1>'; | |
echo '</div>'; | |
} | |
/** | |
* Displays the Testimonials loop. | |
* | |
* @since 1.0.0 | |
* | |
* @package Testimonials by Woo | |
*/ | |
remove_action('genesis_loop', 'genesis_do_loop'); | |
add_action('genesis_loop', 'bigfat_testimonial_do_loop'); | |
function bigfat_testimonial_do_loop() { | |
$args = array( | |
'limit' => 10, | |
'orderby' => 'date', | |
'order' => 'DESC' | |
); | |
do_action( 'woothemes_testimonials', $args ); | |
} | |
genesis(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment