This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TableFilterer.prototype.addClickHandler = function(el,facet,featuredness) { | |
tFinstance = this; | |
$(el).live('click',function() { | |
var entity = $(this).attr("data-"+facet); | |
var type = $(this).children('h4').html(); | |
//for race "permalinks" | |
if (!_.isNaN(parseInt(entity))) { | |
entity = parseInt(entity); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require 'rubygems' | |
require 'yajl/json_gem' | |
module AP | |
# a = AP::ParseData.new('/file.txt') | |
class ParseData | |
def initialize(file) | |
@file = file | |
@ap_scratch = [] | |
@final_results = [] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module Graticule #:nodoc: | |
module Geocoder #:nodoc: | |
class Google | |
def initialize(key) | |
@key = key | |
@proxies = ["http://127.0.0.1:8080", "http://127.0.0.1:8081", "http://127.0.0.1:8082"] | |
@url = URI.parse @proxies[rand(@proxies.length)] + '/maps/geo' | |
end | |
end | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function(){ | |
var $$ = function(query){ | |
!!(query && query.nodeType == 1) ? | |
this.dom = query | |
: | |
this.dom = document.getElementById(query); | |
}; | |
$$.prototype.remove = function(){ | |
this.dom.parentNode.removeChild(this.dom); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function(){ | |
var $$ = function(query){ | |
!!(query && query.nodeType == 1) ? | |
this.dom = query | |
: | |
this.dom = document.getElementById(query); | |
}; | |
$$.prototype.remove = function(){ | |
this.dom.parentNode.removeChild(this.dom); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
(function(){ | |
var $$ = function(query){ | |
!!(query && query.nodeType == 1) ? | |
this.dom = query | |
: | |
this.dom = document.getElementById(query); | |
}; | |
$$.prototype.remove = function(){ | |
this.dom.parentNode.removeChild(this.dom); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var TimelineSetter = window.TimelineSetter = (window.TimelineSetter || {}); | |
var Timeline = TimelineSetter.Timeline = function(){...}; | |
Timeline.boot = function(){ | |
$(function(){ | |
... | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
WD=`pwd` | |
tiger_em () { | |
directory=$WD/$1 | |
shift | |
until [ -z "$1" ] | |
do | |
get_em $directory "ftp://ftp2.census.gov/geo/tiger/TIGER2010/"$1 | |
shift |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def measure | |
t = Time.now | |
yield | |
Rails.logger.info Time.now - t | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html> | |
<head> | |
<link href="stylesheets/timeline-setter.css" rel="stylesheet" /> | |
<script src="javascripts/vendor/jquery-min.js"></script> | |
<script src="javascripts/vendor/underscore-min.js"></script> | |
<script src="javascripts/timeline-setter.js"></script> | |
</head> | |
<body style="height: 100%"> | |
OlderNewer