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( 'genesis_footer_backtotop_text', 'shireman_footer_backtotop_text' ); | |
/** | |
* Customize the return to top of page text | |
* | |
*/ | |
function shireman_footer_backtotop_text( $backtotop ) { | |
$backtotop = '[footer_backtotop text="Return to Top"]'; | |
return $backtotop; | |
} |
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( 'genesis_footer_creds_text', 'shireman_footer_creds_text' ); | |
/** | |
* Customize the footer credits | |
* | |
*/ | |
function shireman_footer_creds_text() { | |
echo '<div class="creds"><p>'; | |
echo 'Copyright © '; | |
echo date( 'Y' ); | |
echo ' · <a href="'.home_url().'">'.get_bloginfo('name').'</a> · Site Design by <a href="http://www.webendev.com/" title="WebEndev LLC">WebEndev</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
add_action( 'genesis_after_post_content', 'we_add_books_edit_link', 5 ); | |
/** | |
* Add Post Edit Link on Published Books CPT Single | |
* | |
*/ | |
function we_add_books_edit_link() { | |
if ( 'we_published-book' == get_post_type() && is_single() ) { | |
echo '<div class="clear">'; | |
edit_post_link( 'Edit', '', '' ); | |
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
add_action( 'get_header', 'shireman_template_check' ); | |
/** | |
* Filter the_content on Blog Page Template | |
* | |
*/ | |
function shireman_template_check() { | |
if ( is_page_template( 'page_blog.php' ) ) | |
add_filter( 'the_content', 'shireman_filter_blog_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
<?php | |
/* | |
Template Name: Novels | |
*/ | |
/** Remove Post Meta and Post Info */ | |
remove_action( 'genesis_before_post_content', 'genesis_post_info' ); | |
remove_action( 'genesis_after_post_content', 'genesis_post_meta' ); | |
/** Add Novels body class */ |
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_header', 'genesis_do_header' ); | |
add_action( 'genesis_header', 'shireman_do_custom_header' ); | |
/** | |
* Modify the default header, including the #title-area div, | |
* along with #title and #description. | |
* | |
* Calls the genesis_site_title, and genesis_site_description. | |
* | |
* Adds book thumbnail display. | |
* |
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( 'request', 'we_complete_column_orderby' ); | |
/** | |
* Sorting for the 'Complete' column in Submissions (we_submission) CPT, browse admin page | |
* | |
*/ | |
function we_complete_column_orderby( $vars ) { | |
if ( isset( $vars['orderby'] ) && 'we_item-complete' == $vars['orderby'] ) { | |
$vars = array_merge( $vars, array( | |
'meta_key' => 'we_item-complete', | |
'orderby' => 'meta_value' |
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
$page = get_page_by_title( 'Submissions Test' ); | |
if ( null == $page ) { | |
$args = array( | |
'post_type' => 'page', | |
'post_title' => 'Submissions Test', | |
'post_status' => 'private', | |
'post_content' => 'This page was automatically created for your theme. This page displays your Submissions entries and SHOULD NOT BE REMOVED.', | |
'comment_status' => 'closed', | |
'ping_status' => 'closed', |
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( 'enter_title_here', 'we_change_submissions_cpt_title' ); | |
/** | |
* Change 'Enter Title Here' text for Submissions CPT | |
* | |
*/ | |
function we_change_submissions_cpt_title( $title ){ | |
$screen = get_current_screen(); | |
if ( 'we_submission' == $screen->post_type ) { | |
$title = 'Enter Site 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
add_action( 'restrict_manage_posts', 'we_add_submissions_taxonomy_filters' ); | |
/** | |
* Add taxonomy filter to the Submissions CPT admin page | |
* | |
*/ | |
function we_add_submissions_taxonomy_filters() { | |
global $typenow; | |
// an array of all the taxonomies you want to display. Use the taxonomy name or slug | |
$taxonomies = array('we_type'); |