Skip to content

Instantly share code, notes, and snippets.

@10h30
10h30 / archive-portfolio.php
Last active August 29, 2015 14:19 — forked from srikat/archive-portfolio.php
Portfolio in Genesis with Featured Images in a Grid revealing Title and Excerpt on Hover. http://sridharkatakam.com/portfolio-genesis-featured-images-grid-revealing-title-excerpt-hover/
<?php
/**
* Portfolio Archive
* Author: Sridhar Katakam
*
*/
//* Add portfolio body class to the head
add_filter( 'body_class', 'sk_add_portfolio_body_class' );
function sk_add_portfolio_body_class( $classes ) {
@10h30
10h30 / functions.php
Created April 16, 2015 01:07 — forked from srikat/functions.php
Revealing Featured Images when hovering on Posts in Whitespace Pro. http://sridharkatakam.com/reveal-featured-images-hovering-posts-whitespace-pro/
add_image_size( 'home-image', 400, 400, true );
@10h30
10h30 / backstretch-set.js
Last active March 7, 2017 09:26 — forked from srikat/backstretch-set.js
Set Featured Image as Header's background using Backstretch in Genesis
jQuery(function( $ ){
$(".site-header").backstretch([BackStretchImg.src],{duration:3000,fade:750});
});
@10h30
10h30 / functions.php
Last active August 29, 2015 14:19 — forked from srikat/functions.php
Display Archive pages by Modified Date in WordPress
add_action( 'pre_get_posts', 'sk_order_posts_by_modified' );
/**
* Arrange Posts by last modified with the most recently updated ones at the top
*
* @author Sridhar Katakam
* @author Bill Erickson <- Boss
* @link http://www.billerickson.net/customize-the-wordpress-query/
* @param object $query data
*
*/
@10h30
10h30 / functions.php
Last active August 29, 2015 14:19 — forked from About2git/functions.php
How to Slide Down Search Box in a Full Screen Overlay in Genesis https://sridharkatakam.com/slide-search-box-full-screen-overlay-genesis/
<?php
//* Do NOT include the opening php tag
//* https://sridharkatakam.com/slide-search-box-full-screen-overlay-genesis/
//* Make Font Awesome available
add_action( 'wp_enqueue_scripts', 'enqueue_font_awesome' );
function enqueue_font_awesome() {
wp_enqueue_style( 'font-awesome', '//maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css' );
}