Restful_authentication

Salut,

j’essay d’utiliser ce plugin
http://www.agilewebdevelopment.com/plugins/restful_authentication
Je n’arrive pas à le faire fonctionner. J’ai installeé la dernière
version
du edge et ajouter la route.

Quand je crée un nouvel utilisateur rien ne se passe ou plus tot il
retourne
à index. Quand je soumet le formulaire rien de rien.

class UsersController < ApplicationController

Be sure to include AuthenticationSystem in Application Controller

instead
include AuthenticatedSystem

If you want “remember me” functionality, add this before_filter to

Application Controller
before_filter :login_from_cookie

render new.rhtml

def new
end

def create
@user = User.new(params[:user])
@user.save!
self.current_user = @user
redirect_back_or_default(’/’)
flash[:notice] = “Thanks for signing up!”
rescue ActiveRecord::RecordInvalid
render :action => ‘new’
end
end

new_rhtml
<%= error_messages_for :user %>
<% form_for :user, :url => users_path do |f| -%>

Login
<%= f.text_field :login %>

Email
<%= f.text_field :email %>

Password
<%= f.password_field :password %>

Confirm Password
<%= f.password_field :password_confirmation %>

<%= submit_tag 'Sign up' %>

<% end -%>

Merci

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs