Skip to content

Instantly share code, notes, and snippets.

View jerrylee's full-sized avatar

Jerry jerrylee

View GitHub Profile
@jerrylee
jerrylee / gist:965c9ecb6f1a26ffca8e
Created November 19, 2015 22:49
Form functionality
<!DOCTYPE html>
<html>
<head>
<script src="https://code.jquery.com/jquery.min.js"></script>
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css" rel="stylesheet" type="text/css" />
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/js/bootstrap.min.js"></script>
<script src="https://code.jquery.com/jquery-2.1.4.js"></script>
<meta charset="utf-8">
<title>JS Bin</title>
</head>
@jerrylee
jerrylee / 01-gulpfile.js
Created June 9, 2017 12:36 — forked from markgoodyear/01-gulpfile.js
Comparison between gulp and Grunt. See http://markgoodyear.com/2014/01/getting-started-with-gulp/ for a write-up.
/*!
* gulp
* $ npm install gulp-ruby-sass gulp-autoprefixer gulp-cssnano gulp-jshint gulp-concat gulp-uglify gulp-imagemin gulp-notify gulp-rename gulp-livereload gulp-cache del --save-dev
*/
// Load plugins
var gulp = require('gulp'),
sass = require('gulp-ruby-sass'),
autoprefixer = require('gulp-autoprefixer'),
cssnano = require('gulp-cssnano'),
@jerrylee
jerrylee / wp-query-ref.php
Created June 28, 2017 17:16 — forked from luetkemj/wp-query-ref.php
WP: Query $args
<?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(
$('.explore-unit').click(function(){
if($(this).hasClass('hide-it')){
$('#side_wrapper').animate({
left:"-500px",
top:"-500px"
});
$(this).removeClass('hide-it');
} else {
$('#side_wrapper').animate({
left:"0",
@jerrylee
jerrylee / gist:cd94bfb2621e4044b67e4eefe3db5ecc
Created September 14, 2018 17:15 — forked from adamrosloniec/gist:a3995cc3aec2537d7ee4
wordpress acf bootstrap carousel - simple example
// bootstrap carousel build with wordpress acf - simple method
// with add class 'active' to first div - MUST BE!
// also you must add css:
// .item {display:none;}
// .item.active {display:block;}
// first method
<ul id="carousel" class="slider carousel" data-ride="carousel" data-interval="<?php if ( get_field('slider__speed','option') ) { the_field('slider__speed','option'); } else { echo '4000'; } ?>"><!-- add sub_field to change slide time --!>
<?php if ( have_rows('slider__item','option') ) : ?> <!-- take slides from Options Page > slider__item -->
<div class="panel-group" id="accordion" role="tablist" aria-multiselectable="true">
<div class="panel panel-default">
<div class="panel-heading" role="tab" id="headingOne">
<h4 class="panel-title">
<a role="button" data-toggle="collapse" data-parent="#accordion" href="#collapseOne" aria-expanded="true" aria-controls="collapseOne">
<?php get_header(); ?>
<!--Slider area start here-->
<section class="slider-area">
<div id="carousel-example-generic" class="carousel slide" data-ride="carousel">
<!-- Indicators -->
<ol class="carousel-indicators">
<li data-target="#carousel-example-generic" data-slide-to="0" class="active"></li>
<li data-target="#carousel-example-generic" data-slide-to="1"></li>
<li data-target="#carousel-example-generic" data-slide-to="2"></li>