I hereby claim:
- I am tayvano on github.
- I am tayvano (https://keybase.io/tayvano) on keybase.
- I have a public key ASBa64mpsHMVdrXgqF_bPTqz7pZxKiudr_d_f-sVvfwDqQo
To claim this, I am signing this object:
//Gives Containers equal heights, using the tallest height and applying it to the other containers | |
//the function takes two arguments, the class of the container of all to-be-equalized containers, and the class of the containers themselves | |
function equalizeContainers(containerClass, targetClass) { | |
//Get all containers of to-be-equalized elements... | |
var containerElements = document.getElementsByClassName(containerClass); | |
//... and iterate through them | |
for(var i = 0; i < containerElements.length; i++) { |
// Smooth Scolling https://css-tricks.com/snippets/jquery/smooth-scrolling/ | |
// the higher the "400" number is, the slower is goes. | |
$(function() { | |
$('a[href*=\\#]:not([href=\\#])').click(function(e) { | |
if (location.pathname.replace(/^\//, '') == this.pathname.replace(/^\//, '') || location.hostname == this.hostname) { | |
var target = $(this.hash); | |
target = target.length ? target : $('[name=' + this.hash.slice(1) + ']'); | |
if (target.length) { | |
$('html,body').animate({ | |
scrollTop: target.offset().top - 110 |
function limit_char($limit, $source=null) { | |
global $post; | |
($source) ? '<p>'.$source.'</p>' : $source = '<p>'.get_the_excerpt().'</p>'; | |
$read_more = '... <a href="'. get_permalink($post->ID) . '" class="more-link" title="Read '.get_the_title($post->ID).'">Read more</a>'; | |
$limited = strlen($source) > $limit ? substr($source,0,strpos($source,' ',$limit)) . $read_more : $source; | |
echo $limited; | |
} |
I hereby claim:
To claim this, I am signing this object:
<?php | |
// SHOW YOAST PRIMARY CATEGORY, OR FIRST CATEGORY | |
$category = get_the_category(); | |
$useCatLink = true; | |
// If post has a category assigned. | |
if ($category){ | |
$category_display = ''; | |
$category_link = ''; | |
if ( class_exists('WPSEO_Primary_Term') ) |
<IfModule mod_expires.c> | |
ExpiresActive on | |
ExpiresDefault "access plus 3 days" | |
# Favicon | |
ExpiresByType image/x-icon "access plus 1 month" | |
# Media: images, video, audio | |
ExpiresByType image/gif "access plus 1 month" |
<div class="lazyImg lazyImg--notloaded" style="background-image: url(<?php echo $hero_bg['sizes']['lazyImg']?>)" data-image="<?php echo $hero_bg['sizes']['hero-bg']?>"></div> | |
<noscript><div style="background-image: url(<?php echo $hero_bg['sizes']['hero-bg']?>)"></div></noscript> | |
function loadLazyImg() { | |
$.each( $('.lazyImg'), function(index, val) { | |
var img = new Image() | |
var src = $(this).attr('data-image') | |
img.src = src | |
var image = $(this) |
<?php | |
/** | |
* WordPress Query Comprehensive Reference | |
* Compiled by luetkemj - luetkemj.com | |
* CODEX: http://codex.wordpress.org/Class_Reference/WP_Query#Parameters | |
* Source: https://core.trac.wordpress.org/browser/tags/3.9/src/wp-includes/query.php | |
*/ | |
$args = array( | |
#!/bin/bash | |
# A script to set up a new mac. Uses bash, homebrew, etc. | |
# Focused for ruby/rails development. Includes many utilities and apps: | |
# - homebrew, rvm, node | |
# - quicklook plugins, terminal fonts | |
# - browsers: chrome, firefox | |
# - dev: iterm2, sublime text, postgres, chrome devtools, etc. | |
# - team: slack, dropbox, google drive, skype, etc |
#!/usr/bin/env bash | |
#Install command-line tools using Homebrew. | |
#Make sure we’re using the latest Homebrew. | |
brew update | |
#Upgrade any already-installed formulae. | |
brew upgrade |