Displaying 20 results from an estimated 2000 matches similar to: "Setting a root_url"
2010 Nov 14
5
Authlogic and rails 3 : NameError in User sessionsController#new
Hi everybody,
I''ve installed Authlogic on Rails 3 following the Railscast (http://
railscasts.com/episodes/160-authlogic), and the resources I was able
to find on the web, but I''m facing a problem.
Once I''ve generated the user_sessions controller and mapped the login
and logout routes, I get an error if I try to load the login page :
uninitialized constant
2011 Jun 29
6
RSpec with Rails 3.1rc4: spec test won't recognize <%= %> (should be simple)
In my user_sessions_controller:
class UserSessionsController < ApplicationController
before_filter :require_no_user, :only => [:create, :new]
before_filter :require_user, :only => :destroy
def new
@user_session = UserSession.new
@message = "Hello."
end
def create
@user_session = UserSession.new(params[:user_session])
if @user_session.save
2009 Aug 02
13
NoMethodError in User sessionsController#create - Authlogic
Hi,
I''m beginner in rails, and I wanted to add to my simple application
Authlogic. So I''ve watched http://railscasts.com/episodes/160-authlogic
and step-by-step done everything. And almost everything works fine,
except login in. After registration new user is automatically logged in,
he can edit his profile, but after clicking logout and trying to login
again I get error
2009 Oct 18
4
NoMethodError in User sessionsController#new
I''m setting up authentication with Authlogic and I get this error.
I''ve done some searching but with no success. I tried setting the
current_user method in Application_controller to protected and not
private, on the recommendation in Stack Overflow.
Error in browser-----------------
NoMethodError in User sessionsController#new
undefined method `require_no_user'' for
2011 Jun 09
8
Fail to call
Hi, I''m trying create a user system for a future project but I have a
problem when I want give to my users the "Welcome". This is my code:
#application_controller
class ApplicationController < ActionController::Base
protect_from_forgery
helper_method :current_user
private
def current_user_session
return @current_user_session if defined?(@current_user_session)
2010 Sep 09
1
NoMethodError in User sessionsController#create
Having a frustrating go at authenticating a user, pretty sure it must
have something to do with gem version conflicts, but I can''t seem to
find a solution that works.
No matter what username & password that is entered into the login form I
get the same error screen:
NoMethodError in User sessionsController#create
undefined method `protected_password'' for #<UserSession:
2010 May 21
0
Authlogic and Single table inheritance
Hi,
I have some models such as:
class User < ActiveRecord::Base
acts_as_authentic
end
class Admin < User
end
class Superadmin < Admin
end
And some controllers such as:
class UserSessionsController < ApplicationController
def new
@user_session = UserSession.new
end
def create
@user_session =
2010 Nov 07
1
Strange authlogic logout behavior
I am using authlogic for my application''s authentication. If I decide
to login with an account and then immediately logout, I get an error.
Unknown action
The action ''show'' could not be found for UserSessionsController
The server log in development says:
Started GET "/user_session" for 127.0.0.1 at Sun Nov 07 13:28:31 -0800
2010
2010 May 25
2
Rails 2.3.6 and Authlogic 2.1.4 or 2.1.3
In the test environment, logging out and back in is not working for me. The
log for the first login looks like this:
Processing UserSessionsController#create (for 127.0.0.1 at 2010-05-24 19:53:57) [POST]
Parameters: {"user_session"=>{"remember_me"=>"true", "password"=>"[FILTERED]", "login"=>"test"},
2011 Jun 01
7
desperate, errors with file upload
hello,
i implementing a file upload using paperclip plugin. i getting the
following error [1] when uploading a file. I''m using the gems rails
v2.3.8 and paperclip v2.1.6. the parameter hash looks like [2], the
model like [3].
Interesting is that i get two different errors, on the localhost with
webrick it says:
Status: 500 Internal Server Error
no marshal_dump is defined for class
2009 Dec 03
2
AuthLogic Question - one time password (persistence_token) - what config is required to use this???
Hi,
I''m stuck trying to work this one out - have been reviewing the
AuthLogic code base but having a hard time making sense of it (
http://github.com/binarylogic/authlogic ).
Question 1 - Can anyone confirm what config exactly is required to
make the one time password (persistence_token) work in AuthLogic? See
below for the bulk...
Question 2 - If not the full answer to the above,
2010 Jun 14
2
stylesheet_link_tag
I know that the following statement loads the scaffold stylesheet, but
what exactly does stylesheet_link_tag do here?
<%= stylesheet_link_tag ''scaffold'' %>
Thanks.
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To post to this group, send email to
2010 Sep 22
8
ActiveScaffold and partials
I was thinking of doing partials as I did in the simple Rails
application I worked on today.
But, since I''m using ActiveScaffold, I didn''t find any *.html.erb in the
views folder of the Rails application that I need to make my partials!
How can I work with partials in ActiveScaffold?
Thanks.
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you
2010 Sep 15
5
Hide an image in show.html.erb
I have the following "show.html.erb" script, and I get as an output TWO
images since I use a method to draw an image.
How can I HIDE the RESOURCE image?
Thanks.
Here is the script:
<canvas id="line" height="512" width="512">
</canvas>
<p id="notice"><%= notice %></p>
<p>
<b> Name </b>
<%=
2010 Oct 21
4
Authlogic + Rails3 - undefined method `Login' for nil:NilClass
Im new to Rails, and decided to start of with Rails3. After a lot of
searching ive managed to get a little bit of Authlogic working. I''m able
to register a user, login & logout.
Now, I would like to add more features, get more of authlogic working.
I''m using Railscast EP 160 as my reference.
Portions of the code found on the tutorial throw errors: Eg:
<!--
2010 Nov 15
0
Problem testing Authlogic UserSession
I''ve posted this to the Authlogic group but things seem a little quiet, so
perhaps someone here can help:
''m testing Authlogic 2.1.6, running under Rails 3.0.1., using rspec
2.1.0
I have the following:
user.rb
class User < ActiveRecord::Base
acts_as_authentic do |config|
config.login_field :email
config.ignore_blank_passwords false
2010 Jul 28
1
paperclip, authlogic and callback issue
I use authlogic for authentication and paperclip for handling user''s
profile picture attachments.
I use the following method to get the current_user
def current_user_session
return @current_user_session if defined?
(@current_user_session)
@current_user_session = UserSession.find
end
def current_user
return @current_user if defined?(@current_user)
2008 Dec 16
20
step definitons to check login
I am working with the authlogic gem and trying to create a simple login
test from cucumber features. The feature statement is:
Given the user is not logged in
The step definition for this is confounding me. In the
application_controller the authlogic tutorial recommends the following:
private
def require_user
unless current_user
store_location
flash[:notice] =
2011 Aug 05
2
Scatter plot in R
Hi,
I have 334 records, with two columns:
Column (1): Resolution Column (2): Number of images with a specific
resolution
How can I make a scatter plot in R with this data? Is there a way to *import
* the records, since it will be time consuming to enter 334 records?
Thanks.
[[alternative HTML version deleted]]
2010 Aug 12
2
session
I tried to understand what a "session" means in Ruby on Rails, and found
this site:
http://www.tutorialspoint.com/ruby-on-rails/rails-session-cookies.htm
But, really, I couldn''t get the idea well yet. Can you just explain what
"session" means mire further?
Thanks.
--
Posted via http://www.ruby-forum.com/.
--
You received this message because you are subscribed to