Most of the JavaScript snippets have code that manipulates the DOM. For that reason dom manipulating javascript code should have...
If you defined your association via class Article belongs_to "category" end and you try Article.scoped(:include => :category)
The following snippet demonstrates how you could create excel files (with spreadsheet gem) and format columns so that they follow...
This describes all the steps you'll need to get Solr up and running for your project using the Sunspot...
Gem to get Rails 3's new ActiveRecord query interface (where, order) and the new scope syntax (chaining scope definitions...
Twitter's Bootstrap CSS blueprint as a jQuery UI theme. Even if you don't want to use Bootstrap as...
Use the command geordi migrate to migrate your databases and to prepare them before running tests. The abbrevation geordi m...
When selecting records in a date range, take care not to do it like this: start_date = Date.parse('2007-05...
jQuery UI's date picker and date time picker doesn't work on touch interfaces. Solution 1: Use Mobiscroll
Although it's tempting flirt with detecting mobile/touch devices with CSS media queries or Javascript feature detection alone, this approach...
Basically, you now need to know if your project uses a "real" time zone or :local, and if config.active_record.time_zone...
The tagged_with scope comes with many awesome options to modify your search: User.tagged_with("awesome", "cool") # Users that are...
In your Cucumber features you can't really click hidden elements when using Selenium (it does work for a plain...
If you're using Paperclip to store and convert images attached to your models, processing a lot of images will...
Association named 'variations' was not found; perhaps you misspelled it? I just was hunting down a strange error with this...
When you're getting this error, one possibility is that you've created a select field for an association instead...
When internationalizing your Rails app, you'll be replacing strings like 'Please enter your name' with t('.name_prompt'). You...
When you have a complex recipe setup with multistage deployment you may run into this error: `role_list_from': unknown...
The SQL code generated by Graticule's spherical distance computation is insufficient and can lead to NULL distances in edge...
Seems like a useful gem for cases where ActiveRecord is overkill but you don't want to do everything by...
I introduced DataMapper on my last two major projects. As those projects matured after I had left, they both migrated...
Using rename_column, remove_column, etc. more than once in a migration makes that migration run slower than it should...
Gem to generate entity relationship diagrams from your Rails 3 ActiveRecord models. The diagram style is pretty and configurable.
For performance improvements (and to remove the need for eager loading), the ActsAsTaggableOn gem supports caching your tag lists directly...