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
/** | |
* HTML5 DOCTYPE | |
* removes the default Genesis doctype, adds new html5 doctype with IE8 detection | |
*/ | |
function mb_html5_doctype() { | |
?> | |
<!DOCTYPE html> | |
<!--[if IE 8]> <html class="lt-ie9" <?php language_attributes( 'html' ); ?>> <![endif]--> | |
<!--[if gt IE 8]><!--> <html <?php language_attributes( 'html' ); ?>> <!--<![endif]--> |
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
/* Column Classes | |
Link: Link: http://wpsmith.net/2013/wp/genesis-2-0-drops-fifths-from-column-classes/ | |
Link: http://twitter.github.io/bootstrap/assets/css/bootstrap-responsive.css | |
--------------------------------------------- */ | |
.five-sixths, | |
.four-sixths, | |
.four-fifths, | |
.one-fifth, | |
.one-fourth, |
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 | |
// rewrite the tribe event featured image on single event view templates with a custom size | |
function custom_tribe_event_featured_image( $featured_image ){ | |
if( is_single() ){ | |
$post_id = get_the_ID(); | |
$size = 'hbgm-news-full'; | |
$image_src = wp_get_attachment_image_src( get_post_thumbnail_id( $post_id ), $size ); | |
$featured_image = ''; | |
if ( !empty( $image_src ) ) { |
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_responsive_slider_query_args', 'custom_genesis_responsive_slider_query_args'); | |
function custom_genesis_responsive_slider_query_args($query_args) { | |
$term_args = array( ); | |
if ( 'page' != genesis_get_responsive_slider_option( 'post_type' ) ) { | |
if ( genesis_get_responsive_slider_option( 'posts_term' ) ) { |
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 | |
// Don't copy the opening <?php tag above | |
// Add page title to blog page template | |
add_action( 'genesis_before', 'wsm_blog_page_title' ); | |
function wsm_blog_page_title() { | |
if ( is_page_template( 'page_blog.php' ) ) { | |
add_action( 'genesis_before_content', 'wsm_show_blog_page_title_text', 2 ); | |
} | |
} |
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
add_action( 'genesis_before_content', 'wpsites_before_post_image' ); | |
function wpsites_before_post_image() { | |
if ( !is_page() ) return; | |
if ( $image = genesis_get_image( 'format=url&size=post-image' ) ) { | |
printf( '<a href="%s" rel="bookmark"><img class="post-photo" src="%s" alt="%s" /></a>', get_permalink(), $image, the_title_attribute( 'echo=0' ) ); | |
} | |
} |
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
function full_width_featured_image() { | |
if(is_single()) | |
echo '<div class="featured-image">Add Your Text or HTML Here</div>'; | |
}; | |
add_action('genesis_before_content_sidebar_wrap', 'full_width_featured_image', 5 ); |
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 | |
$args = array( | |
'post_status'=>'publish', | |
'post_type'=>array(TribeEvents::POSTTYPE), | |
'posts_per_page'=>10, | |
//order by startdate from newest to oldest | |
'meta_key'=>'_EventStartDate', | |
'orderby'=>'_EventStartDate', | |
'order'=>'DESC', |
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
// This snippet goes in functions.php | |
add_filter('agentpress_featured_listings_widget_loop', 'child_ap_listings_loop_filter', 10, 1 ); | |
/** | |
* Adds some additional button classes to the more link | |
* | |
* These button classes are already defined in the theme | |
* style.css file. Adding them to the listing wrap "more link" | |
* will give the "View Listing" buttons styling that is | |
* consistent with the theme. | |
*/ |