Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <?php
- remove_action( 'genesis_entry_content', 'genesis_do_post_image', 8 );
- add_action( 'genesis_entry_header', 'sk_do_post_image', 4 );
- function sk_do_post_image() {
- $image_args = array(
- 'size' => 'home-featured-image'
- );
- echo '<div class="home-featured-image"><a href="' . get_permalink() . '">' . genesis_get_image( $image_args ) . '</a></div>';
- }
- add_action( 'genesis_entry_header', 'genesis_post_meta', 4 );
- remove_action( 'genesis_entry_header', 'genesis_post_info', 12 );
- add_filter( 'genesis_attr_entry-header', 'sk_genesis_attributes_entry_header' );
- /**
- * Add attributes for entry header element.
- *
- * @param array $attributes Existing attributes.
- *
- * @return array Amended attributes.
- */
- function sk_genesis_attributes_entry_header( $attributes ) {
- $attributes['class'] = 'entry-header one-half first';
- return $attributes;
- }
- add_filter( 'genesis_attr_entry-content', 'sk_genesis_attributes_entry_content' );
- /**
- * Add attributes for entry content element.
- *
- * @param array $attributes Existing attributes.
- *
- * @return array Amended attributes.
- */
- function sk_genesis_attributes_entry_content( $attributes ) {
- $attributes['class'] = 'entry-content one-half';
- return $attributes;
- }
- add_action( 'genesis_entry_footer', 'sk_post_info' );
- function sk_post_info() {
- echo '<div class="one-half first">';
- genesis_post_info();
- echo '</div>';
- }
- remove_filter( 'the_content', 'sharing_display', 19 );
- remove_filter( 'the_excerpt', 'sharing_display', 19 );
- add_action( 'genesis_entry_footer', 'sk_social_sharing_buttons' );
- function sk_social_sharing_buttons() {
- if ( function_exists( 'sharing_display' ) ) {
- echo '<div class="one-half">'. sharing_display() . '</div>';
- }
- }
- //* Modify the Excerpt read more link
- add_filter('excerpt_more', 'new_excerpt_more');
- function new_excerpt_more($more) {
- return '<p><a class="more-link" href="' . get_permalink() . '">Read More ยป</a></p>';
- }
- //* Customize the entry meta in the entry footer
- add_filter( 'genesis_post_meta', 'sp_post_meta_filter' );
- function sp_post_meta_filter($post_meta) {
- $post_meta = '[post_categories before="Filed Under: "] [post_tags before="| Tagged With: "]';
- return $post_meta;
- }
- genesis();
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement