Skip to content

Instantly share code, notes, and snippets.

Sridhar Katakam srikat

Block or report user

Report or block srikat

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View page_filterable-portfolio.php
* Template Name: Filterable Portfolio
* By Sridhar Katakam ( based on Adapt Theme (
srikat / functions.php
Last active Apr 23, 2019
Force a layout for Pages that have subpages in Genesis.
View functions.php
// Apply layout to static Pages that have children (subpages)
add_action( 'get_header', 'sk_force_layout' );
function sk_force_layout() {
global $post;
// if we are on a static Page and if it does not have a parent
if ( is_singular( 'page' ) && !$post->post_parent ) {
add_filter( 'genesis_pre_get_option_site_layout', '__genesis_return_content_sidebar' );
srikat / style.css
Last active Apr 23, 2019
Subtitles below Titles in Genesis using Visual Subtitle plugin.
View style.css
.subtitle {
display: block;
margin-top: 10px;
.breadcrumb .subtitle {
display: none;
View functions.php
// Remove default header opening markup function
remove_action( 'genesis_header', 'genesis_header_markup_open', 5 );
// Add back header opening markup function w/o the structural wrap
add_action( 'genesis_header', 'sk_header_markup_open', 5 );
function sk_header_markup_open() {
genesis_markup( array(
'html5' => '<header %s>',
'xhtml' => '<div id="header">',
View page-child-theme.php
add_action( 'genesis_loop', 'sk_custom_loop' );
function sk_custom_loop() {
$themes = array(
'Agency Pro' => 'agency-pro',
'Agentpress Pro' => 'agentpress-pro',
'Altitude Pro' => 'altitude-pro',
'Ambiance Pro' => 'ambiance-pro',
View functions.php
// Add Google Tag Manager code in <head>
add_action( 'wp_head', 'sk_google_tag_manager1' );
function sk_google_tag_manager1() { ?>
<!-- Google Tag Manager -->
new Date().getTime(),event:'gtm.js'});var f=d.getElementsByTagName(s)[0],
<!-- End Google Tag Manager -->
srikat / functions.php
Last active Apr 16, 2019
Display Portfolio CPT's linked taxonomy terms (categories and tags) in Genesis entry meta.
View functions.php
add_shortcode( 'portfolio_terms', 'custom_portfolio_terms_shortcode' );
* Produces the linked post taxonomy terms list.
* Supported shortcode attributes are:
* after (output after link, default is empty string),
* before (output before link, default is 'Tagged With: '),
* sep (separator string between tags, default is ', '),
* taxonomy (name of the taxonomy, default is 'category').
View functions.php
add_filter( 'genesis_seo_title', 'custom_header_inline_logo', 10, 3 );
* Add an image inline in the site title element for the logo
* @param string $title Current markup of title.
* @param string $inside Markup inside the title.
* @param string $wrap Wrapping element for the title.
* @author @_AlphaBlossom
* @author @_neilgee
View functions.php
* Genesis Sample.
* This file adds functions to the Genesis Sample Theme.
* @package Genesis Sample
* @author StudioPress
* @license GPL-2.0+
* @link
View functions.php
// Add custom opening div for post title
add_action( 'genesis_entry_header', 'sk_do_post_title_before', 7 );
function sk_do_post_title_before() {
echo '<div class="my-entry-title">';
// Add custom closing div for post title
add_action( 'genesis_entry_header', 'sk_do_post_title_after' );
function sk_do_post_title_after() {
echo '</div>';
You can’t perform that action at this time.