I want to start a new web-based project in Ruby on Rails. One of the features I want is for people to register on the site but then have the site send them an email to confirm it is valid. Can anyone suggest how I should start? Are there components/plugins/engines I should look at that can cut some of the development time?
ActionMailer should do what you want.
You like cheese? You like peas? You'll love cheezy peas!
Making sure the user is verified should be easy enough once you figure out how to mail them...you can just make a flag in the database to show that they're approved. I'd probably generate a random confirmation key of some sort, email them that key, and then have them enter the key into a confirmation form. If they match, flag them as confirmed and allow them to log in...
I found the login engine (relies on actionmailer) which I *think* will do all this:
I'm a bit confused as to how to set up my mysql database though. There is a section in the readme that says:
=== Create the DB schema After you have done the modifications the the ApplicationController and its helper, you can import the user model into the database. An ActiveRecord schema.rb file is provided in login_engine/db/schema.rb, along with migration information in login_engine/db/migrate/.
Not sure what to make of that.. I'm used to getting a .sql file that I can import into MySQL. Anyone have any experience with this?
Looks like they're using ActiveRecord Migrations. It's actually a very good feature to help keep things database agnostic and is an easy way to manage database changes/updates over time (including the ability to rollback to previous database schemas). Try googling around for 'ruby on rails migrations' or 'migrations schema.rb' and you'll find a ton of decent articles on how to use it.