アクティベーションメールの送信に関するこのチュートリアルに従っています。
http://www.slideshare.net/JamesEdwardGrayII/sending-email-with-rails
これはレール2で行われたと確信しており、ルーティングは私にとって少し問題がありました。
routes.rb:
map.activate "activate/:token", :controller => "activations", :action => "create"
有効にする:
activate_url(:token => @user.perishable_token, :host => "localhost:3000")
そのlocalhost:3000/:token
ため、ユーザーがアクティブ化するためにURLが送信されます。
Rails 3で機能させるために、私は次のことを試しました。
match 'activate/:token' => 'activations#create'
match 'activate/:token', :to => 'activations#create'
しかし、機能しactivate_url
ていません。いくつかの入力をいただければ幸いです。ありがとう!