Skip to content

Instantly share code, notes, and snippets.

View jeisc's full-sized avatar

John Eischen jeisc

View GitHub Profile
// by Erik Wrenholt
import java.util.*;
class Mandelbrot
{
static int BAILOUT = 16;
static int MAX_ITERATIONS = 1000;
private static int iterate(float x, float y)
{
if (typeof window.localStorage == 'undefined' || typeof window.sessionStorage == 'undefined') (function () {
var Storage = function (type) {
function createCookie(name, value, days) {
var date, expires;
if (days) {
date = new Date();
date.setTime(date.getTime()+(days*24*60*60*1000));
expires = "; expires="+date.toGMTString();

Awesome PHP Libraries

A list of amazingly awesome PHP libraries that you should consider using (and some other shiny extras).

Awesome PHP Libraries

A list of amazingly awesome PHP libraries that you should consider using (and some other shiny extras).

@jeisc
jeisc / location.js
Created January 22, 2013 08:16 — forked from n1k0/location.js
var page = require('webpage').create();
var base = phantom.args[0];
var path = phantom.args[1];
var expected = phantom.args[2];
page.onNavigationRequested = function(url, navigationType, navigationLocked, isMainFrame) {
console.log('Navigation requested: ' + navigationType + '; ' + url);
if (!page.testStarted) {
return;
}
@jeisc
jeisc / 404checker.js
Created January 22, 2013 08:16 — forked from n1k0/404checker.js
/**
* This casper scipt checks for 404 internal links for a given root url.
*
* Usage:
*
* $ casperjs 404checker.js http://mysite.tld/
* $ casperjs 404checker.js http://mysite.tld/ --max-depth=42
*/
/*global URI*/
@jeisc
jeisc / windows.h__.js
Created November 19, 2012 19:24
windows.h.js INFINITY
var ffi = require('ffi'),
ref = require('ref'),
Struct = require('ref-struct'),
Library = require('./Library'),
Type = ref.Type,
NULL = ref.NULL,
isNull = ref.isNull;
var groups = ['libs', 'types', 'structs', 'callbacks', 'enums'];
@jeisc
jeisc / Excel.php
Created February 19, 2012 08:16 — forked from ihumanable/Excel.php
Simple Excel Writer in PHP
<?php
/**
* Simple excel writer class with no external dependencies, drop it in and have fun
* @author Matt Nowack
* @license Unlicensed
* @version 1.0
*/
class Excel {
private $col;
@jeisc
jeisc / index.html
Created April 27, 2011 18:18 — forked from mrspeaker/index.html
Collection mapping test: jQuery vs jQuery vs JavaScript
<!DOCTYPE html>
<html>
<head>
<title>Collection mapping: jQuery vs jQuery vs JavaScript</title>
</head>
<body>
<h1>Comparing Maps</h1>
<h2>jQuery vs jQuery vs JavaScript</h2>
<p>Output is in the JavaScript console.</p>
<p>For more info, view source (or visit <a href="http://www.mrspeaker.net/2011/04/27/reducing-map/">Mr Speaker's "reducing map"</a>)
<?php
/**
* Simple excel writer class with no external dependencies, drop it in and have fun
* @author Matt Nowack
* @license Unlicensed
* @version 1.0
*/
class Excel {
private $col;