Multiple Images with PaperClip

For any given web application, you probably want your users to be able to embed pictures or other types of multimedia for a richer experience...

Aug 14, 2014 on Rails Ruby Paperclip  0

NullUser On Rails

The Null Object Pattern is a popular software pattern that can be very useful as it can get rid of many nil checks in Ruby...

Aug 11, 2014 on Rails Ruby Authentication SoftwarePatterns  0

You're so vain, you probably think this URL is about you.

In Ruby on Rails, when you want to make a particular route that has a parameter with spaces in it, you would typically get something like /regions/new%20york...

Aug 08, 2014 on Rails Ruby ActiveRecord Prettyurls  0

Ruby Enumerable, Part 2

The Enumerable module can be used for all of your Ruby classes as long as they implement their own each method...

Aug 06, 2014 on Ruby  0

Keep Your Queries DRY with Eager Loading

The N + 1 query problem can be very tricky to deal with or even find because you won't be typically dealing with a lot of data in development mode...

Aug 01, 2014 on Rails Ruby Performance  0

Ruby Enumerable, Part 1

The Enumerable module in Ruby can be used for arrays and hashes and can save you from writing complex, nested if statements and loops...

Jul 31, 2014 on Ruby  0

Javascript on Rails

The Javascript syntax is not nearly as fun as Ruby's but you must use it if you want to do anything dynamic on the client-side...

Jul 24, 2014 on Rails JavaScript Ajax  0

Polymorphic Controllers???

That's right, polymorphic controllers in Ruby on Rails...

Jul 21, 2014 on Polymorphism Rails Ruby Metaprogramming RegularExpressions  0

Polymorphism, Very Difficult? Or Suprisingly Simple?

I have heard of a polymorphic relationship before, and it was difficult to wrap my head around but it is actually very simple, as it has similarities with ...

Jul 18, 2014 on Polymorphism Rails Ruby  0

User has_many selfies

When creating a self referential join through another table, you must think of each entry as a new row even if two of the columns have the same number, but...

Jul 16, 2014 on Rails Ruby ActiveRecord  0