jamesgolick / resource_controller at Github module ResourceController module Actions def index load_collection before :index response_for :index end
When doing a query like this: SELECT id FROM users WHERE (users.id IN (899,1084,1095,100,2424,2429,2420...
An alternative to this technique is using VCR. VCR allows you to record and replay real HTTP responses, saving you...
In a nutshell: to avoid your shell character set from messing with imports, use -r to export and SOURCE when...
ALTER DATABASE database_name CHARACTER SET "utf8"; ALTER DATABASE database_name COLLATE "utf8_unicode_ci"; After that, for...
Ancestry is a gem/plugin that allows the records of a Ruby on Rails ActiveRecord model to be organised as a...
This may be awkward to set up, but will work once you're done. Fun facts:
Unless all MySQL server defaults are set to UTF-8, mysqldump encodes UTF-8 characters incorrectly and only outputs correct...
Most of these will not work in newer projects because these use the Capybara/Rack::Test combo in lieu of Webrat...
ActsAsSolr::Post.execute(Solr::Request::Delete.new(:query => "#{Location.solr_configuration[:type_field]}:#{ModelClass}")) ActsAsSolr::Post.execute(Solr::Request::Commit.new)
This can happen during development when classes without automatic reloading are pointing to classes with automatic reloading. E.g. some class...
You are getting when connecting via SSH or deploying with Capistrano (which uses SSH): Too many authentication failures for username...
When you include a non-existing Javascript file, you probably won't notice it during development. But with caching active...
Gem to provide nice looking urls ("/blog/the-greatest-bug-i-never-fixed"). If you don't need anything too special (like i18n for the urls...
A while back, I had a requirement to persist a record of which email addresses were sent an email through...
List of Rails releases.
Reads Active Record's validations and makes them available to live client side javascript
Rails’ script/console makes it easy to fetch, view and edit your database records. But can you edit those records as...
PNG transparency for IE 6.
MMM (MySQL Master-Master Replication Manager) is a set of flexible scripts to perform monitoring/failover and management of MySQL Master...
Record Filter gives you the full power of ActiveRecord's query building tools with a heaping helping of DSL thrown...
The idea behind scrooge is both surprisingly simple and powerful: instead of forcing the developer to manually specify each attribute...
After some deliberation, we decided to implement a "schema-less" storage system on top of MySQL rather than use a...
Store schema-less data in MySQL.