This file contains hidden or 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 | |
| remove_action( 'genesis_entry_content', 'genesis_do_post_content' ); | |
| remove_action( 'genesis_entry_header', 'genesis_post_info', 12 ); | |
| remove_action( 'genesis_entry_footer', 'genesis_entry_footer_markup_open', 5 ); | |
| remove_action( 'genesis_entry_footer', 'genesis_post_meta' ); | |
| remove_action( 'genesis_entry_footer', 'genesis_entry_footer_markup_close', 15 ); | |
| //* Reposition Archive Pagination |
This file contains hidden or 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( 'wp_enqueue_scripts', 'hp_enqueue_scripts_styles' ); | |
| function hp_enqueue_scripts_styles() { | |
| /**** Masonry load scripts ****/ | |
| if ( is_home() || is_archive() ) { | |
| wp_enqueue_script ( 'jquery-masonry'); | |
| wp_enqueue_script ( 'masonry-init' , get_stylesheet_directory_uri() . '/js/masonry-init.js', array('jquery-masonry'), '1', true ); | |
| } | |
| /**** Masonry CSS ****/ |
This file contains hidden or 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
| jQuery( document ).ready( function( $ ) { | |
| jQuery( '.content' ).masonry(); | |
| } ); | |
| jQuery( 'img' ).load(function() { | |
| jQuery( '.content' ).masonry(); | |
| } ); |
This file contains hidden or 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
| .masonry .entry { | |
| padding: 1px; | |
| margin: 7px; | |
| width: 100%; | |
| overflow: hidden; | |
| } | |
| .masonry .entry h2 { | |
| font-size: 15px; | |
| font-size: 1.5rem; | |
| position: absolute;; |
This file contains hidden or 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 an extra body class ****/ | |
| add_filter( 'body_class', 'hp_body_class' ); | |
| function hp_body_class( $classes ) { | |
| $classes[] = 'masonry'; | |
| return $classes; | |
| } |
This file contains hidden or 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( 'template_redirect', 'fb_change_search_url_rewrite' ); | |
| function fb_change_search_url_rewrite() { | |
| if ( is_search() && ! empty( $_GET['s'] ) ) { | |
| wp_redirect( home_url( "/search/" ) . urlencode( get_query_var( 's' ) ) ); | |
| exit(); | |
| } | |
| } | |
| add_filter('rewrite_rules_array','hp_myRewrites'); | |
| function hp_myRewrites( $rules ) |
This file contains hidden or 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( 'edit_post_link', '__return_null' ); |
This file contains hidden or 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 version information **** | |
| function hp_remove_script_version( $src ) { | |
| $parts = explode( '?ver', $src ); | |
| return $parts[0]; | |
| } | |
| add_filter( 'script_loader_src', 'hp_remove_script_version', 15, 1 ); | |
| add_filter( 'style_loader_src', 'hp_remove_script_version', 15, 1 ); |