Almost since the beginning I’ve had RESTful Authentication setup on ArcadeFly, although I’d been too lazy to setup a mail server to test of it’s functionality. For testing this out though, I decided to give Google a shot thanks to an article on how to use gmail as your mail serevr for rails. Very easy to implement, although I’m still unsure on the exact limitations. I don’t expect to reach any of those during development though, so for now it’s going to serve as an easy configuration option between the two PCs I use to code.
With that out of the way time to worry about a few smaller issues. Created a signup form at www.ArcadeFly.com. If you’re curious as to why I’m going with the www prefix, it’s mostly because of the site’s audience. For a mostly tech offering, or a tech blog I understand it makes perfect sense to do it the “right” way and use just the domain (we’re doing that for Adogo), but since this will be mostly video gamers and hopefully some not-as-technical people, adding www seems like the way to go. Non-www still forwards that way of course, and I don’t doubt that there will be a huge intersection of progammers and gamers.
Aside from that I learned a little bit about just how Rails Observers work. Such a simple topic I see why I don’t read too much more about it. There’s surely more to it than I’ve found, but it begins with a “config.active_record.observers” option in the environment.rb file where you point it to a classname. For RESTful authentication, for example, you’d point it to :user_observer. This will handle automatically sending out email messages based on changes to the user object. For instance, the UserObserver class is an ActiveRecord::Observer and shares methods like “after_create”, “after_save” and other points. Very powerful feature that’s easy to implement.