Skip to content

Instantly share code, notes, and snippets.


Aaron Snowberger jekkilekki

View GitHub Profile
jekkilekki /
Last active Jan 18, 2021
New Website (WordPress) Helpers

New Website (WordPress) Helpers

These website building helpers are originally extracted from the WordPress TwentyTwenty Theme and are intended to provide easy access to some of the most common basic styles for a website.

This Gist will be occasionally updated with my own preferences for these styles. Files include the following:

File Purpose
jekkilekki /
Created Sep 22, 2015
Social Menu Code from Justin Tadlock

Register Social menu in functions.php

register_nav_menus( array(
    'top'     => esc_html__( 'Top Menu', 'theme-slug' ),
    'social'  => esc_html__( 'Social Menu', 'theme-slug' ),
) );

Create menu in inc/template-tags.php

jekkilekki / slide-in-images.css
Created Jan 10, 2017
Slide in as you scroll down boxes
View slide-in-images.css
* Sliding Image Panels
.slide-panel:not(first-child) {
border-top: 1px solid #ddd;
.slide-panel .entry-header {
width: 58%;
.slide-panel .entry-content {
jekkilekki /
Created Oct 21, 2016
Clone ALL branches of a git repo
# From Ray Villalobos' course on AngularJS2
# @link
git clone --bare .git # Clones a bare version of the repo
git config --bool core.bare false # Switch bare repo to normal version of the repo
git reset --hard # Repo resets to the master branch at the latest commit
jekkilekki / Fix Vagrant nginx
Last active Nov 13, 2017
Vagrant Nginx binding error fix
View Fix Vagrant nginx

I was the following problems with my VVV installation earlier this year. The following are the steps I took to fix things:

Update to PHP7

Since November PHP7 is the default for VVV, but at that time (Sept/Oct), it was not. But it was included on the [develop] branch (not [master]) of VVV.

  1. Switch to [develop] : git checkout develop
  2. git pull

nginx not binding to port 80

jekkilekki /
Last active Jul 27, 2017
Make a Back to Top button in WordPress
jekkilekki / taxonomy-dropdowns.js
Created Nov 21, 2016
WordPress taxonomy dropdowns - if too long (default is to show all taxonomies)
View taxonomy-dropdowns.js
jQuery(document).ready(function($) {
* For Taxonomy dropdowns in Post meta
$( '.cat-links .jkl-tax-switch, .tags-links .jkl-tax-switch' ).click( function( e ) {
if( $( this ).next( 'ul' ).hasClass( 'childopen' ) ) {
$( this ).next( 'ul' ).removeClass( 'childopen' );
} else {
jekkilekki / customizer-pseudo-elements.js
Last active Feb 6, 2017
Use a Background Gradient in WP Customizer + Various other Customizer functions
View customizer-pseudo-elements.js
* Make the WP Customizer also recognize and adjust pseudo- elements like :before and :hover
* Non-instantaneous update - requires partial page refresh
// Highlight colors
wp.customize( 'highlight_color', function( value ) {
value.bind( function( to ) {
$( 'a:visited, a:hover, a:focus, a:active, .entry-content a, .entry-summary a' ).css( {
jekkilekki / lifeData.csv
Last active Jan 25, 2017
Data for D3.js Radar Chart
View lifeData.csv
section twenty14 twenty15 twenty16
Physical 3 4 6
Mental 5 4 6
Spiritual 4 3 2
Career 2 5 6.5
Financial 4 2 7
Family 5 6 4
Relationships 3 5.5 5
Lifestyle 4 5 3
jekkilekki /
Last active Jan 19, 2017
D3 Pie Chart