Join Newsletter


Share with:

Recent Posts

Jason Fleetwood-Boldt

When using Paperclip to save an attached image, how do I get & store the dimensions of the image? Best way is to create two fields to store the width & height and then just populate those fields when the image loads. (Other solutions, like reading it dynamically each, incur a lot of unnecessary disk activity.) Be sure to checkout some basic tutorials on Paperclip if you are unfamiliar with it generally. (see references below 1 2 3)

Step by step instructions.

1. create a new file at lib/paperclip_processors/thumbnail_with_dimensions.rb

2. Paste the contents of this gist into the newly created file:

This is the 76th NY Tech meetup; September is going to be the 6th year anniversary. Nate has a little self back-patting before getting to the show. Nate toutes his work brokering a connection for NY high school students to get placed as interns at...

Read More

Usual round-up of tonight's NYTM with my brief annotations. - A personal betterment site. "Learn look and feel better." Helps independent freelances find clients. Online booking system, availability is displayed and clients can book freelancers online. Nice look site, looks like it could be rails,...

Read More

OK, so I feel it is officially time to kill IE 6 and below. IE 6 has been the bane of web developers' existence for quite some time now. I say, just kill it. If your product manager whines and says "but we need to...

Read More

The most dramatic thing at tonight's New York Tech Meetup was, far and away, Scott Heifferman, founder of, smashing an iPad on stage (yes, it was a real iPad). Perhaps the furor over Apple's ubiquitous onslaught of advertising got to him, perhaps it was...

Read More

Some experimentation with the text-overflow property. <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"    ""><html>  <body><div style="border: 1px solid red; max-width: 400px; overflow:hidden; text-overflow: ellipsis;"><nobr>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Vestibulum ac libero nec est luctus aliquam. Nulla sodales, dolor a consectetur volutpat, elit mi convallis sem, at...

Read More