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_filter( 'agentpress_featured_listings_widget_loop', 'agentpress_featured_listings_widget_loop_filter' ); | |
/** | |
* Filter the loop output of the AgentPress Featured Listings Widget. | |
* | |
*/ | |
function agentpress_featured_listings_widget_loop_filter( $loop ) { | |
$loop = ''; /** initialze the $loop variable */ | |
$loop .= sprintf( '<a href="%s">%s</a>', get_permalink(), genesis_get_image( array( 'size' => 'feature-community' ) ) ); |
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 | |
/** | |
* | |
* @package Genesis\Templates | |
* @author Josh Hathcock | |
* @license GPL-2.0+ | |
* @link http://my.studiopress.com/themes/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
// Edit Site Title | |
remove_action( 'genesis_site_title', 'genesis_seo_site_title' ); | |
add_action( 'genesis_site_title', 'jds_seo_site_title' ); | |
function jds_seo_site_title() { | |
echo '<h1 id="title"><a href="#">JDSpiral</a></h1>'; | |
} |
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 H1 from title and add logo | |
add_filter( 'genesis_seo_title', 'jds_header_title', 10, 3 ); | |
function jds_header_title( $title, $inside, $wrap ) { | |
$inside = sprintf( '<div itemscope="itemscope" itemtype="http://schema.org/Organization"><a itemprop="url" href="%s" title="%s"> | |
<img class="logo" itemprop="logo" src="' . get_stylesheet_directory_uri() . '/images/logo.png" alt="%s" width="" height="" /> | |
</a></div>', trailingslashit( home_url() ), esc_attr( get_bloginfo( 'name' ) ), get_bloginfo( 'name' ) ); | |
return sprintf( '<%1$s id="title">%2$s</%1$s>', 'span', $inside ); | |
} |
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
// Enable Shortcode in widgets - Note: This is not recommended. This is plugin functionality. | |
add_filter('widget_text', 'do_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
//* Customize the post info function | |
remove_action( 'genesis_entry_header', 'genesis_post_info', 12); | |
add_action( 'genesis_entry_header', 'genesis_post_info', 9 ); | |
add_filter( 'genesis_post_info', 'jds_post_info_filter' ); | |
function jds_post_info_filter($post_info) { | |
if (is_home() || is_archive()) { | |
$post_info = '[post_categories before=""] [post_comments] [post_edit]'; | |
return $post_info; | |
} |
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 featured image | |
add_action ( 'genesis_entry_header', 'jds_featured_image', 15); | |
function jds_featured_image() { | |
if ( is_single() ) | |
return; | |
if ($image = genesis_get_image('format=url&size=thumbnail')) { | |
echo '<div class="alignleft">'; | |
printf('<a href="%s"><img class="alignleft" src="%s" alt="%s" /></a>', get_permalink(), $image, the_title_attribute('echo=0')); | |
echo '</div>'; | |
} |
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
//Custom Image Sizes | |
add_image_size( 'featured-image', 236, 153, TRUE ); |
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
// Edit Read More Link | |
add_filter('post-content-shortcodes-read-more', 'jds_more_visit_site'); | |
function jds_more_visit_site($link) { | |
return str_ireplace('Read more', 'Read More...', $link); | |
} |
OlderNewer