Skip to content

Instantly share code, notes, and snippets.


J.P. Given iamjpg

Block or report user

Report or block iamjpg

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
iamjpg / toast.js
Created May 30, 2019
Vitruvius Toast Signature
View toast.js
import Toast from 'path_to_toast_js';
let toast = new Toast();{
type: 'success',
header: 'This is a Header',
message: 'This toast was created with the "removeIn" option meaning this toast will dissapear in 5 seconds.',
removeIn: 5000,
iamjpg / PhysicalLatLonToPixelXY.html
Last active Sep 19, 2018
Google Maps v3 – Translate Physical Latitude/Longitude into Screen Pixel X/Y
View PhysicalLatLonToPixelXY.html
<!DOCTYPE html>
<html lang="en">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
body {
margin: 0;
iamjpg /
Created Aug 22, 2012 — forked from cowboy/
jQuery Tiny Pub/Sub: A really, really, REALLY tiny pub/sub implementation for jQuery.
/* jQuery Tiny Pub/Sub - v0.7 - 10/27/2011
* Copyright (c) 2011 "Cowboy" Ben Alman; Licensed MIT, GPL */
(function($) {
var o = $({});
$.subscribe = function() {
o.on.apply(o, arguments);
iamjpg / gist:3194394
Created Jul 28, 2012
The Iron by Henry Rollins
View gist:3194394
This article originally appeared in Details Magazine some time around 1994 or 1995, I believe. This is a great essay by Henry Rollins on the benefits and lessons of lifting weights.
I believe that the definition of definition is reinvention. To not be like your parents. To not be like your friends. To be yourself.
When I was young I had no sense of myself. All I was, was a product of all the fear and humiliation I suffered. Fear of my parents. The humiliation of teachers calling me "garbage can" and telling me I'd be mowing lawns for a living. And the very real terror of my fellow students. I was threatened and beaten up for the color of my skin and my size. I was skinny and clumsy, and when others would tease me I didn't run home crying, wondering why.
iamjpg / gist:3044289
Created Jul 4, 2012
Reactive Image jQuery Plugin
View gist:3044289
// Written by: J.P. Given
// jgiven { at } gmail { com }
(function ( $, window ) {
var pluginName = 'reactiveImage',
pl = null,
document = window.document,
defaults = {
iamjpg / server.js
Created Nov 21, 2011 — forked from jeffrafter/server.js
Twitter OAuth with node-oauth for node.js+express
View server.js
var express = require('express');
var sys = require('sys');
var oauth = require('oauth');
var app = express.createServer();
var _twitterConsumerKey = "YOURTWITTERCONSUMERKEY";
var _twitterConsumerSecret = "YOURTWITTERCONSUMERSECRET";
function consumer() {
iamjpg / gist:1304547
Created Oct 21, 2011
View gist:1304547
%script{:type => "text/javascript"}
$('body').attr('data-sitebase', "#{request.url}");
$('body').attr('data-agenttoken', "6f62a0d9-479d-4e16-a473-90e671c65979");
var search_height = $(window).height() - $('#shared-footer').outerHeight(true) - $('#shared-header').outerHeight(true);
var search_width = $(window).width();
iamjpg / gist:1302277
Created Oct 20, 2011
Javascript Riddle
View gist:1302277
<!DOCTYPE html>
<html lang="en">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>JS Riddle</title>
<h3>Print 0 to 100 to the browser without using a global variable in JS</h3>
<div id="print"></div>
View Android Layout With Buttons Pinned on Bottom
<?xml version="1.0" encoding="utf-8"?>
You can’t perform that action at this time.