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 <?php on editing */ | |
$creds = 'Copyright [footer_copyright] <a href="'.get_bloginfo( 'url' ).'">'.get_bloginfo( 'name' ).'</a></p><p>Developed by <a href="#">XYZ</a>'; |
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 <?php on editing */ | |
$creds = 'Copyright [footer_copyright] <a href="'.get_bloginfo( 'url' ).'">'.get_bloginfo( 'name' ).'</a><p>Developed by <a href="#">XYZ</a></p>'; |
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 <?php on editing */ | |
// Change the footer text | |
add_filter( 'genesis_footer_creds_text', 'sp_footer_creds_filter' ); | |
function sp_footer_creds_filter( $creds ) { | |
$creds = 'Copyright [footer_copyright] <a href="'.get_bloginfo( 'url' ).'">'.get_bloginfo( 'name' ).'</a>'; | |
return $creds; | |
} |
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 | |
//* Display views count after entry title on single entry | |
add_action( 'genesis_entry_header', 'post_views_count' ); | |
function post_views_count() { | |
if ( ! is_singular( 'post' ) ) | |
return; | |
echo post_views(get_the_ID()); |
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 | |
// Register a custom image size for Singular Featured images | |
add_image_size( 'singular-featured-thumb', 800, 250, true ); | |
add_action( 'genesis_before_entry', 'sk_display_featured_image' ); | |
function sk_display_featured_image() { | |
if ( ! is_singular( array( 'post', 'page' ) ) ) { | |
return; | |
} |
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('wp_enqueue_scripts', 'sp_style_sheet'); | |
function sp_style_sheet() { | |
wp_enqueue_style( 'custom-style', get_stylesheet_directory_uri() . '/custom.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
<?php | |
add_filter( 'the_content', 'sp_adsense_first_paragraph' ); | |
function sp_adsense_first_paragraph ( $content ) { | |
if ( !is_single() ) | |
return $content; | |
$paragraphAfter = 2; //Enter paragraph number | |
$content = explode ( "</p>", $content ); | |
$new_content = ''; |
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
/** | |
* Adds Featured Image and links it to the Post | |
* | |
* @author Wes Straham | |
* @since 1.0.0 | |
*/ | |
add_action( 'genesis_before_post_content', 'epik_portfolio_do_post_image' ); | |
function epik_portfolio_do_post_image() { | |
$img = genesis_get_image( array( | |
'format' => 'html', |
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 support for 4-column footer widgets | |
add_theme_support( 'genesis-footer-widgets', 4 ); |
NewerOlder