We’re moving on October 1

Our new address is: 400-1668 Barrington St. Halifax NS B3J 2A2 Come visit us!


Custom user delete in Devise

Devise's default behaviour to delete a user is to actually delete them from the database. This isn't the right approach for every site; in my case, I prefer to hang on to users in perpetuity and simply mark their record as deleted. The steps are simple. Create a migration: def up add_column :users, :deleted_at, :timestamp end When deleted_at gets a value, we'll consider the record deleted. Otherwise, it is active. Now we need to change the log in behaviour to check if the user has been deleted or not. Devise provides the valid_for_authentication? method, which you


This is Part 3 of a series of tutorials. Here's Part 1 and Part 2. So we've covered models, collections, controllers, and the basic case of tying a view to a model's callbacks. Now we're going to cover tying a view to a collection. This gets a little hairy, so I'm going to keep it nice and simple to start. Note: As with most things, there are large number of ways you could do this. If you feel that you have a better way, feel free to


Next hacks@ on Saturday 26 February at 4:30 p.m.

The next hacks@ is on 26 February at 4:30 p.m. Read more and sign up.


JavaScript talk at PodCamp Halifax 2011

I had the opportunity to speak at PodCamp Halifax 2011 this past Sunday January 23 on the topic “JavaScript & jQuery – What it is, How to use it, and Why it’s the future of the web”. Given the predominantly social media audience of the conference, I kept the talk fairly low-tech, breaking the talk into 3 parts: A history of JavaScript and jQuery Where JavaScript started. Why we hated it (popups! popunders! marquees! dropdown navigation that didn’t work!) Why developers looked down their noses at JS for years. The introduction of Ajax and how it changed the web world, being the technological start