Skip to content

Instantly share code, notes, and snippets.

View cre8tivediva's full-sized avatar

Anita cre8tivediva

  • 20:54 (UTC -04:00)
View GitHub Profile
@cre8tivediva
cre8tivediva / Clear fix for Genesis Column Classes
Created April 1, 2018 20:40 — forked from ifamily/Clear fix for Genesis Column Classes
This CSS will fix problems caused by Genesis Column Classes of uneven height. Just add a div with the class name of clear-line to your code. Then add this to your .css file.
/*
Clear fix for column classes
---------------------------------------------------------------------------------------------------- */
.clear-line:after {
content: ".";
display: block;
clear: both;
visibility: hidden;
line-height: 0;
height: 0;
@cre8tivediva
cre8tivediva / columns.css
Created April 1, 2018 20:39 — forked from studiopress/columns.css
Genesis column classes.
/* Column Classes
Link: http://twitter.github.io/bootstrap/assets/css/bootstrap-responsive.css
--------------------------------------------- */
.five-sixths,
.four-sixths,
.one-fourth,
.one-half,
.one-sixth,
.one-third,
@cre8tivediva
cre8tivediva / content.php
Created December 27, 2017 18:44
Responsive Video iFrame Code
<div class="video-code">ADD YOUR IFRAME</div>
@cre8tivediva
cre8tivediva / page_landing.php
Last active December 19, 2017 04:19
Custom Landing Page for Swank Child Theme
<?php
/**
* Custom Landing Page for the Swank Child Theme
*
* This file adds the landing page template to the Swank Child Theme.
*
* Template Name: Landing
*
* @package Custom Landing Page for Swank
* @author Anita Carter
@cre8tivediva
cre8tivediva / functions.php
Last active November 25, 2017 19:39
Add Comments to Portfolio Post Type
// Add Comments to Portfolio Custom Post Type (https://codex.wordpress.org/Function_Reference/add_post_type_support)
function add_comments_portfolio() {
add_post_type_support( 'portfolio', 'comments' );
}
add_action( 'init', 'add_comments_portfolio', 11 );
@cre8tivediva
cre8tivediva / functions.php
Last active September 19, 2017 20:29
Add Color Selector and New Color to Maker Pro Child Theme
//* Add support for additional color style options
add_theme_support( 'genesis-style-selector', array(
'maker-dark' => __( 'Maker Dark', 'maker' ),
'maker-medium' => __( 'Maker Medium', 'maker' ),
) );
@cre8tivediva
cre8tivediva / functions.php
Last active May 28, 2024 03:43
Rename the Genesis Portfolio Slug
<?php
//* Do NOT include the opening php tag shown above. Copy the code shown below.
//* Updated 5/26/2024 to reflect changes to the plugin
function rename_portfolio_custom_post_type_slug() {
// Get the post type object
$post_type_object = get_post_type_object( 'portfolio' );
// Convert the post type object to an array to manipulate its arguments
$args = (array) $post_type_object;
@cre8tivediva
cre8tivediva / functions.php
Created April 9, 2017 00:32
Add Simple Product CPT
// Register Custom Post Type
function products_post_type() {
$labels = array(
'name' => _x( 'Products', 'Post Type General Name', 'text_domain' ),
'singular_name' => _x( 'Product', 'Post Type Singular Name', 'text_domain' ),
'menu_name' => __( 'Products', 'text_domain' ),
'name_admin_bar' => __( 'Product', 'text_domain' ),
'archives' => __( 'Item Archives', 'text_domain' ),
'attributes' => __( 'Item Attributes', 'text_domain' ),
@cre8tivediva
cre8tivediva / functions.php
Last active March 1, 2017 21:37
Related Posts by One Category (modified from Nick Croft's code - http://designsbynickthegeek.com/tutorials/related-posts-genesis)
//for XHTML themes
add_action( 'genesis_after_post_content', 'child_related_posts' );
//for HTML5 themes
add_action( 'genesis_after_entry_content', 'child_related_posts' );
/**
* Outputs related posts with thumbnail
*
* @author Nick the Geek
* @url http://designsbynickthegeek.com/tutorials/related-posts-genesis
* @global object $post
@cre8tivediva
cre8tivediva / style.css
Created February 9, 2017 06:32
Hide Previous/Next Arrows and Pager Link Buttons from Free Version of Soliloquy
/*
Hide Previous/Next Arrows and Pager Link Buttons from Free Version of Soliloquy
---------------------------------------------------------------------------------------------------- */
.soliloquy-container .soliloquy-prev,
.soliloquy-container .soliloquy-next,
.soliloquy-container .soliloquy-pager-link {
display: none !important;
}