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( 'init', ‘cmk_add_excerpts_to_pages' ); | |
function cmk_add_excerpts_to_pages() { | |
add_post_type_support( 'page', 'excerpt' ); | |
} |
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
// Bring back the missing editor for Posts page | |
add_action( 'edit_form_after_title', 'rgc_posts_page_edit_form' ); | |
function rgc_posts_page_edit_form( $post ) { | |
$posts_page = get_option( 'page_for_posts' ); | |
if ( $posts_page === $post->ID ) { | |
add_post_type_support( 'page', 'editor' ); | |
} |
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
// Register Horizontal Opt-in widget area | |
genesis_register_widget_area( | |
array( | |
'id' => 'horizontal-opt-in', | |
'name' => __( 'Horizontal Opt-in', 'my-theme-text-domain' ), | |
'description' => __( 'This is the horizontal opt-in section.', 'my-theme-text-domain' ), | |
) | |
); | |
// Display Horizontal Opt-in widget area below header |
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
image: savjee/docker-s3website-git-ftp-deploy | |
pipelines: | |
default: | |
- step: | |
script: | |
- git ftp init --user $FTP_USERNAME --passwd $FTP_PASSWORD ftp://s1.closemarketing.net/domains/domain.com/public_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
//* Adding WordPress Taxonomy title and description (category, tag, taxonomy) | |
add_action( 'genesis_before_loop', 'cmk_output_category_info' ); | |
function cmk_output_category_info() { | |
if ( is_category() || is_tag() || is_tax() ) { | |
echo '<div class="archive-description">'; | |
echo '<h1 class="archive-title">'; | |
echo single_term_title(); |
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 | |
/** | |
* Use the built-in post counter | |
* | |
* Sometimes you'll want to keep track of which post you're on in a loop. | |
* Some people create their own $loop_counter (ex: Genesis, https://gist.github.com/4675237 ). | |
* There's a better way! A loop counter is built into $wp_query. Ex: | |
* | |
* global $wp_query; | |
* echo $wp_query->current_post |
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
// Display 24 products per page. Goes in functions.php | |
add_filter( 'loop_shop_per_page', create_function( '$cols', 'return 24;' ), 20 ); |
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 prices | |
remove_action( 'woocommerce_after_shop_loop_item_title', 'woocommerce_template_loop_price', 10 ); |
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
// Removes showing results | |
remove_action( 'woocommerce_before_shop_loop', 'woocommerce_result_count', 20 ); |
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
// Removes showing results | |
remove_action( 'woocommerce_before_shop_loop', 'woocommerce_result_count', 20 ); |