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 lang=“en”> | |
<head> | |
<meta charset="utf-8"> | |
<title>About | Janet Ferguson Full Stack Web Developer</title> | |
<!--[if lt IE 9]> | |
<script src="dist/html5shiv.js"></script> | |
<![endif]--> | |
</head> | |
<body> |
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
# http://forrst.com/posts/JSON_vs_Marshal_vs_eval_Which_is_the_fastest_fo-6Qy | |
require 'benchmark' | |
require 'json' | |
require 'redis' | |
# ----------------- | |
puts "Initialize variables.." |
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
# Inspired by https://gist.github.com/1172097 | |
alphabet = Hash[ | |
:a => "dit dah", | |
:b => "dah dit dit dit", | |
:c => "dah dit dah dit", | |
:d => "dah dit dit", | |
:e => "dit", | |
:f => "dit dit dah dit", | |
:g => "dah dah dit", |
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
class Object | |
def collapse | |
memcache.store :key => object_id, :value => ENV["HOST_NAME"] | |
end | |
def persist | |
database.insert object_id, Marshall.dump(self) | |
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
$.password | |
:blur | |
if @value === "" | |
.hide() | |
// Eventually, indenting beneath something will set it as the context | |
.prev() | |
.show().val(@default_value) | |
.blur() | |