This gist is part of a blog post. Check it out at:
http://jasonrudolph.com/blog/2011/08/09/programming-achievements-how-to-level-up-as-a-developer
#step 1 - installation | |
sudo gem install sparql | |
#step 2 - test | |
# in test.rb | |
require 'sparql/client' | |
sparql = SPARQL::Client.new("http://dbpedia.org/sparql") |
This gist is part of a blog post. Check it out at:
http://jasonrudolph.com/blog/2011/08/09/programming-achievements-how-to-level-up-as-a-developer
function popupCenter(url, width, height, name) { | |
var left = (screen.width/2)-(width/2); | |
var top = (screen.height/2)-(height/2); | |
return window.open(url, name, "menubar=no,toolbar=no,status=no,width="+width+",height="+height+",toolbar=no,resizable=yes,scrollbars=yes,left="+left+",top="+top); | |
}; | |
/* Usage by example */ | |
jQuery('.auth_form').submit(function(e){ | |
var $form = jQuery(this); |
development: | |
adapter: postgresql | |
username: studentify | |
host: 127.0.0.1 | |
port: 5432 | |
password: smarty_pens | |
database: studentify_development | |
test: | |
adapter: postgresql |
ActiveRecord::RecordInvalid in SessionsController#new | |
Validation failed: Photo /tmp/stream20120208-13082-389z2b.txt is not recognized by the 'identify' command., Photo /tmp/stream20120208-13082-389z2b.txt is not recognized by the 'identify' command. |
<!DOCTYPE html> | |
<html> | |
<head> | |
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.js"></script> | |
<style type="text/css"> | |
svg { | |
background: #333; | |
} |
<!DOCTYPE html> | |
<html> | |
<head> | |
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.js"></script> | |
<style type="text/css"> | |
svg { | |
background: #333; | |
} |
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta http-equiv="Content-type" content="text/html; charset=utf-8"> | |
<title>Testing Pie Chart</title> | |
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.js?2.1.3"></script> | |
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.geom.js?2.1.3"></script> | |
<script type="text/javascript" src="http://mbostock.github.com/d3/d3.layout.js?2.1.3"></script> | |
<style type="text/css"> |
{ | |
"nodes": [ | |
{ | |
"name": "Myriel", | |
"group": 1 | |
}, | |
{ | |
"name": "Napoleon", | |
"group": 1 | |
}, |
# If not running interactively, don't do anything | |
[ -z "$PS1" ] && return | |
# add local bin path | |
PATH=$HOME/.bin:$PATH | |
PATH=/usr/local/bin:$PATH | |
PATH=/usr/local/sbin:$PATH | |
PATH=/usr/local/mysql/bin:$PATH | |
# don't put duplicate lines in the history |