Skip to content

Instantly share code, notes, and snippets.

View jcanfield's full-sized avatar
💭
If I do not respond quickly, try me on Twitter at @creativeboulder.

Joshua Canfield jcanfield

💭
If I do not respond quickly, try me on Twitter at @creativeboulder.
View GitHub Profile
@jcanfield
jcanfield / gist:2862616
Created June 3, 2012 08:48 — forked from boucher/gist:1750368
Stripe sample checkout form
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<title>Stripe Sample Form</title>
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.6.2/jquery.min.js"></script>
<script type="text/javascript" src="https://ajax.aspnetcdn.com/ajax/jquery.validate/1.8.1/jquery.validate.min.js"></script>
<script type="text/javascript" src="https://js.stripe.com/v1/"></script>
<script type="text/javascript">
@jcanfield
jcanfield / webhook-mailer.php
Created June 8, 2012 16:08 — forked from boucher/webhook-mailer.php
Stripe Webhook PHP Example
<?php
// SETUP:
// 1. Customize all the settings (stripe api key, email settings, email text)
// 2. Put this code somewhere where it's accessible by a URL on your server.
// 3. Add the URL of that location to the settings at https://manage.stripe.com/#account/webhooks
// 4. Have fun!
// set your secret key: remember to change this to your live secret key in production
// see your keys here https://manage.stripe.com/account
<html xmlns:fb="http://ogp.me/ns/fb#">
<head prefix="og: http://ogp.me/ns# fb: http://ogp.me/ns/fb# oghowto: http://ogp.me/ns/fb/oghowto#">
<title>OG Tutorial App</title>
<meta property="fb:app_id" content="256521937796214" />
<meta property="og:type" content="oghowto:demo" />
<meta property="og:title" content="Open Graph HowTo" />
<meta property="og:image" content="http://placehold.it/200x200" />
<meta property="og:description" content="Minimum requirements to get Open Graph objects and actions working" />
<meta property="og:url" content="http://oghowto.herokuapp.com/test.html">
<style type="text/css">
@jcanfield
jcanfield / bootstrap-paged-navar.js
Created July 9, 2012 19:42 — forked from mattsgarrison/bootstrap-paged-navar.js
CoffeeScript and JavaScript results to enhance Twitter Bootstrap navbar's "active" tab for multiple pages (essentially supplanting scrollspy).
// Generated Output from CoffeeScript
jQuery(function() {
var a, b, c, d, e;
d = $(".topbar .nav a"), e = [];
for (b = 0, c = d.length; b < c; b++)
a = d[b], e.push(function(a) {
if (window.location.pathname === a.pathname)
return $(a).parent().toggleClass("active")
}(a));
return e
@jcanfield
jcanfield / dabblet.css
Created July 27, 2012 14:37 — forked from qhwa/dabblet.css
CSS3 progress bar
/**
* CSS3 progress bar
* desgin: http://dribbble.com/shots/522214-Progress-Bar
*/
body {
background-image: repeating-linear-gradient(0, #3C3540 0, #3C3540 50%, #38313B 50%, #38313B 100%);
background-size: 3px 1px;
}
.prog-bar {
@jcanfield
jcanfield / cache.htaccess
Created August 10, 2012 22:49 — forked from kurtpayne/cache.htaccess
.htaccess caching rules
<IfModule mod_mime.c>
# Text
AddType text/css .css
AddType application/x-javascript .js
AddType text/html .html .htm
AddType text/richtext .rtf .rtx
AddType text/plain .txt
AddType text/xml .xml
@jcanfield
jcanfield / nettest.sh
Created August 26, 2012 16:37 — forked from rahulsom/nettest.sh
MacbookPro5,1 has a serious problem with it's wireless. Apple will not acknowledge it, but here's a fix
#!/bin/sh
#
# Tests network status and resets Airport if required
#
usage() {
cat << EOF
Usage: $0 options
-h HOST host to ping
-s <ON|OFF> say out loud: on or off default: OFF
@jcanfield
jcanfield / gist:3773311
Created September 23, 2012 22:43 — forked from ocean90/gist:1544377
Compiling Compass.app on Mac OS X
Tutorial for compiling the Compass.app (http://compass.handlino.com/)
=====================================================================
Java installed?
java -version
Load jRuby (for example JRuby 1.6.5.1 Binary .zip)
http://jruby.org/download
Unzip jRuby to `/usr/local/`
@jcanfield
jcanfield / grid.scss
Created September 23, 2012 22:58
Grid generator as SASS mixin (part of PlainPage 2.0 framework)
// @mixin grid($columnCount:12, $unitRatio: 3, $width: 100%) {
// @param $columnCount
// Qty of columns. Defaults to 12.
// @param $unitRatio
// Column to gutter ratio. All grids are ususally build around grid units. Defaults to 3.
// @param $width
// Grid width. If specified in %, grid automatically becomes fluid.
// @return
// CSS markup for fluid or fixed grid.
@mixin grid($columnCount:12, $unitRatio: 3, $width: 100%) {
#Landscaping With Frontend Development Tools
An opinionated list of tools for frontend (i.e. html, js, css) desktop/laptop (i.e. does not include tablet or phone yet) web development
##Coding Tools
######Workflow/Builds/Assemblers