similar to: RuntimeError with Rails Recipe "Authenticating Your Users"

Displaying 20 results from an estimated 6000 matches similar to: "RuntimeError with Rails Recipe "Authenticating Your Users""

2006 Jun 05
1
file_column permissions
this is getting frustrating... i installed file_column without a hitch for the first time to just play around with. using the exact same steps as before, i try to use it with one of my actual applications, and i get "permission denied" errors. i figure there might be some conflict with my application so just for kicks i do the exact same thing i did the first time to test
2007 Aug 17
1
Scaffold (Agile Web Development With Rails)
What am I doing wrong here? [app/controllers/admin_controller.rb] class AdminController < ApplicationController before_filter :authorize def index list render :action => ''list'' end # GETs should be safe (see http://www.w3.org/2001/tag/doc/whenToUseGet.html) verify :method => :post, :only => [ :destroy, :create, :update ],
2006 Aug 17
6
NameError in AdminController#index building scaffold
I''m a pretty big newbie with ROR, but when following a tutorial I encounter an ugly error when building a scaffold. Here is my environment Dev system: - Windows XP - java version "1.5.0_06" - MySQL java version "1.5.0_06" - Ruby 1.8.4 - Ruby Gems 0.9.0 - Gem install mysql Successfully installed mysql-2.7.1-mswin32 Installing ri documentation for
2006 Jun 02
2
I need help with my 1st sortable list!
Ill keep it brief. Dragging an item is working but dropping and updating the list gives me this error - NoMethodError in AdminController#sort You have a nil object when you didn''t expect it! You might have expected an instance of Array. The error occured while evaluating nil.each #{RAILS_ROOT}/app/controllers/admin_controller.rb:171:in `sort'' # My view - <ul
2006 Jul 07
13
Rails Recipes Book: Authentication
Hi, The user/login management system in Chapter 31: Authenticating Your Users and Chapter 32: Authorizing Users with Roles of Chad Fowler''s Rails Recipes looks reasonable and adequate. However, when I ran the Chapter 31 code, I get the following error: Username or password invalid And I am not even given the chance to sign in; that is, the signin form does not appear at all. Has
2006 Sep 06
5
admin controller problem
I am reading the agile web development with rails book, and starting to create the depot. I am getting the below error after setting up the "ruby script/generate scaffold Product Admin" does anyone know what the problem is? NameError in AdminController#index uninitialized constant Mysql RAILS_ROOT: ./script/../config/../ Application Trace | Framework Trace | Full Trace
2006 Apr 21
1
Catch authentication result from a model in a controller
Im still following the authorization recipe from the book, now all works fine but im getting trouble in how handle the model authorization result, if the user and pass are correct, it goes to a welcome screen(admin.rhtml) but if wrong the model prints a message in an ugly exception like page "usr and pass not correct", i want to redirect the user to the login
2006 Jan 30
2
Modules, controllers and inheritance
Hi! I was trying to cleanup my app and I runned into quite a problem. My controllers in submodule do not seem to inherit things from base class. I have following setup: app/controllers/ application.rb: class ApplicationController admin/ admin_controller.rb: class Admin::AdminController < ApplicationController include LoginEngine include UserEngine
2006 Jun 29
1
Newbie: Help Please - Model Validation Error
Hi, I''d be grateful for your help. I get the error (see below) everytime I add the following into a newly generated (via scaffold) model class: validates_presence_of :myname, :mymessage, :mytel Without it, I can insert records into my database. With it, I get the error :( ERROR>> ArgumentError in AdminController#create wrong number of arguments (1 for 0) RAILS_ROOT:
2006 Apr 27
2
problematic admin/views
ok, i have a pretty almost finished (frontend) blog, i have defined an admin zone with authentication to add content, now im getting trouble with the views for the controllers in the admin zone, here you can see my file structure: http://img284.imageshack.us/my.php?image=tmpviews6oq.gif and my admin controllers like this: controllers/admin/admin_controller.rb class Admin::AdminController
2006 Jul 25
0
Errors logged but not returned to browser, WEBrick hangs
An app I''ve been developing has been chugging along nicely, but around the time I added a new join model a couple of commits ago, my development environment has been acting screwy. 1. When there''s an error, the error messages and tracebacks are not being returned to the browser. The browser keeps the connection alive indefinitely. 2. Stopping the request from the browser
2007 Jun 11
2
Testing create in Rails controller
Hi All So I am a first-time caller ;-) ... and have been trying to apply RSpec to the depot example in Dave Thomas'' book as I build the application. I am having a problem testing the admin controller create method and cannot quite see where I am going wrong so was hoping for a pointer :-) My spec looks like: describe AdminController do before(:each) do @product =
2006 Apr 27
7
Role Based Authorization recipe implementation?
i got the rails recipes book, i have now an auth system for users without problems, now i want to made a role based acces for my app, im following the "Role Based Authorization" recipe of the book but i cant make it to work even when the tables created and correctly added data manually definig the roles and rights. als i dont know how to define a right for use all the actions in a
2008 Jan 18
15
scaffold :product missing in Rails 2.0.2 version of depot tutorial?
I am getting an error when I try to run the code for the depot application (page 67 in the Agile Web Development on Rails book, 2nd edition). I built the complete depot app with Rails 1.2.6, and all worked well. I then updated to Gem 1.0.1 and RoR 2.0.2, and attempted to repeat the tutorial, and got this strange behavior. I used "rails depot --database=mysql" because I have not
2006 Jun 14
6
Lost Connection to MySQL
Error Message: MyMysql::Error: Lost connection to MySQL server during query: SHOW FIELDS FROM products Running Fedora 5, using available Red Hat modules and latest version of Rails. This problem just appeared. I had been enjoying going through the tutorial "Depot" when it started displaying this problem. With phpMyAdmin I am able to access the depot_development data base containing
2008 Nov 28
1
Rails Beginner.. NoMethodError
Dear all I encounter error when I login my Web application NoMethodError in AdminController#login undefined method `get_title'' for #<Class:0x63ac78> Here is part of my code controller/admin_controller.rb def login session[:user_id] = nil if request.post? if User.authenticate(params[:name], params[:password]) user = User.find_by_name(params[:name])
2006 Apr 30
0
Role based auth recipe from a subfolder?
Hi guys, I have implemented the recipe for role based auth in the book, it works perfect(after sometime of pain to make it work fine), im using class inheritance to authenticate all the classes from one point(class AdminController in this case) i have this base structure: class AdminController < ApplicationController ... end class ArticlesController < AdminController ... end i define
2006 Aug 12
5
Simple Newbie db ???
I''m trying to simply write to a mysql db from the console. Model = Entry , table = entries Problem is my values keep getting turned into instance variables and end up nil. >> Entry.create(:title =>"new title", :body => "Brand new body") => #<Entry:0x27178c4 @attributes={"body"=>nil, "title"=>nil, "id"=>6},
2006 Jan 08
9
URL/Site structure
Greetings, I''m fairly noob with rails and making my first DB driven site with it. I''m using the scaffold generator to develop the admin side of my site (admin_controller) I have three sections that I want to have the administrator edit, and I want to call these from the admin controller that has a layout with navigation to these three sections. When using the scaffold
2006 Aug 15
3
update or alter cart
I want to modify and update the items in the Depot - "display_cart". Since the cart is in a session, its a little hard to get at the data. I just want to create a way to change quantities, prices and recalculate. Has someone done this, and could you point me to the right direction. Thanks Chas -- Posted via http://www.ruby-forum.com/.