Skip to content

Instantly share code, notes, and snippets.

View ashby's full-sized avatar

Ashby Utting ashby

View GitHub Profile
@ashby
ashby / SS: Junior
Last active August 29, 2015 14:00
SS: Junior
@charset "UTF-8";
@font-face {
font-family: "SSJunior";
src: url('ss-junior.eot');
src: url('ss-junior.eot?#iefix') format('embedded-opentype'),
url('ss-junior.woff') format('woff'),
url('ss-junior.ttf') format('truetype'),
url('ss-junior.svg#SSJunior') format('svg');
font-weight: 400;
font-style: normal;
@ashby
ashby / ACF: Repeater Loop
Last active August 29, 2015 14:00
ACF: Repeater Loop
<?php if(get_field('repeater_field_name')): ?>
<?php while(has_sub_field('repeater_field_name')): ?>
<?php the_sub_field('sub_field'); ?>
<?php endwhile; ?>
<?php endif; ?>
@ashby
ashby / ACF: Repeater with Flexslider
Last active January 30, 2019 07:08
ACF: Repeater with Flexslider
<?php if(get_field('repeater_field_name')): ?>
<div class="flexslider">
<ul class="slides">
<?php while(has_sub_field('repeater_field_name')): ?>
<li>
<img src="<?php the_sub_field('sub_field'); ?>" />
</li>
<?php endwhile; ?>
</ul>
</div>
@ashby
ashby / ACF: Post Object
Last active January 30, 2018 01:50
ACF: Post Object
<?php $post_objects = get_field('post_objects'); ?>
<?php if( $post_objects ): ?>
<?php foreach( $post_objects as $post): ?>
<?php setup_postdata($post); ?>
<?php the_title(); ?>
<?php endforeach; ?>
<?php wp_reset_postdata(); ?>
<?php endif; ?>
@ashby
ashby / BS: Tabs HTML
Last active August 29, 2015 14:00
BS: Tabs HTML
<button type="button" class="btn btn-danger" data-toggle="collapse" data-target="#demo">
</button>
<div id="demo" class="collapse in"></div>
@ashby
ashby / BS: Collapse HTML
Last active August 29, 2015 14:00
BS: Collapse HTML
<button type="button" class="btn btn-danger" data-toggle="collapse" data-target="#demo"
</button>
<div id="demo" class="collapse in"></div>
@ashby
ashby / CSS: Nth-child Odd
Last active August 29, 2015 14:00
CSS: Nth-child Odd
nth-child(odd)
@ashby
ashby / CSS: Caret Size
Last active August 29, 2015 14:00
CSS: Caret Size
border-top: 4px solid;
border-right: 4px solid transparent;
border-left: 4px solid transparent;
@ashby
ashby / WP: WP_Query
Last active August 29, 2015 14:01
WP: WP_Query
$args = array();
$the_query = new WP_Query( $args );
if ( $the_query->have_posts() ) {
while ( $the_query->have_posts() ) {
$the_query->the_post();
@ashby
ashby / GIT: .gitignore
Last active August 29, 2015 14:01
GIT: .gitignore
.htaccess
wp-config.php
logs/
wp-content/upgrade/
wp-content/uploads/
wp-content/debug.log
# W3 Total Cache
wp-content/cache/*
!wp-content/cache/index.html