Skip to content

Instantly share code, notes, and snippets.

View jonmagic's full-sized avatar

Jonathan Hoyt jonmagic

View GitHub Profile
<fieldset class="ss">
<div class="row">
<label>Work:</label>
<span><a href="tel:5745551212">574-555-1212</a></span>
</div>
<div class="row">
<label>Work:</label>
<span><a href="mailto:[email protected]">[email protected]</a></span>
Grilled Greek Potato Salad
http://img197.yfrog.com/i/il9.jpg/
1.5 pounds of small red potatoes, halved
1 Tbsp of olive oil
salt to taste (don't forget the greek olives will add a lot of salt to the taste)
pepper to taste
1 red and yellow pepper (we used mini sweet peppers)
[11:14] <Jonathan Hoyt>
what i expected was something like this
[11:14] <Jonathan Hoyt>
<div class="inline inline_photo align_right">
<img src="images/intro_pic.png"></a>
</div>
[11:14] <Jonathan Hoyt>
what i'm getting is something like this
#!/usr/bin/perl -w
# Small program to process a tiff file into a PDF and email it.
#
# Distributed under the terms of the GNU General Public License (GPL) Version 2
# Copyright 2005 by Rob Thomas ([email protected])
use MIME::Base64;
use Net::SMTP;
# get some fruit!
orange = { "name": "Orange", "owners": [{ "Jon": 2 }, { "Steve": 5 }] }
apple = { "name": "Apple", "owners": [{ "Jon": 4 }, { "Bill": 2 }] }
pear = { "name": "Pear", "owners": [{ "Jon": 1 }, { "Tom": 3 }] }
# save the fruit
db.foo.save(orange)
db.foo.save(apple)
db.foo.save(pear)
# get some fruit!
orange = { "name": "Orange", "owners": [{ "Jon": 2 }, { "Steve": 5 }] }
apple = { "name": "Apple", "owners": [{ "Jon": 4 }, { "Bill": 2 }] }
pear = { "name": "Pear", "owners": [{ "Jon": 1 }, { "Tom": 3 }] }
# save the fruit
db.foo.save(orange)
db.foo.save(apple)
db.foo.save(pear)
require 'pp'
require 'rubygems'
require 'mongo_mapper'
require 'benchmark'
MongoMapper.database = 'testing'
class Foo
include MongoMapper::Document
db.ticket_items.find()
error: {"_id" : ObjectId( "4b100a29be36154d4ec50047") , "$err" : "Invalid BSONObj spec size"}
require "test_helper"
require File.expand_path(File.dirname(__FILE__) + '/../lib/grip')
class Foo
include MongoMapper::Document
include Grip
has_grid_attachment :image
has_grid_attachment :pdf
# install required packages for building
sudo apt-get install build-essential libssl-dev libreadline5-dev
# download and install ruby
wget ftp://ftp.ruby-lang.org/pub/ruby/1.8/ruby-1.8.7-p248.tar.gz
tar zxvf ruby-1.8.7-p248.tar.gz
cd ruby-1.8.7-p248
./configure
make
sudo make install