Displaying 20 results from an estimated 30000 matches similar to: "filter_parameter_logging and https"
2007 Sep 09
1
filter_parameter_logging
Hi,
Is there a way to specify keys of a hash in params to
filter_parameter_logging.
For example, my payment form sends creditcard[:number] and
creditcard[:type] in params and I filter these keys using
filter_parameter_logging :number, :type.
I don''t want :number and :type in other forms to be filtered. Is there
a way to solve this?
thanks,
Ritesh
2009 May 08
1
filter_parameter_logging for multi model forms
Hi all,
I have a multi model form setup in the classic Ryan Bates Complex
forms style (railscasts.com/episodes/73) for my signup page.
The two models in this are the Account model and the User model and
this structure cannot be changed right now. The User model has
password and password_conf attributes which are, unfortunately, taken
alongwith the rest of the User''s attributes into an
2008 Jun 21
15
will_paginate generates undefined method paginate
Dear
I used to use the will_paginate plugin, and now it is no longer
available in the repository.
I am using the one in the gem
#gem install will_paginate
in my controller I have this
@careers = Career.paginate :page => params[:page], :per_page => 10
and in the view
<%= will_paginate @careers %>
I found this way in all the tutorials and the railscasts episode 51.
Though I still
2009 Mar 05
4
before_filter :action_name OR :action_name
Hi there
I am wondering if we can use before_filter in the form of :action
OR :action
what i want to do is to implement one of the actions, if the first
failed, then go to the second
when i use
before_filter :action1
before_filter :action2
each method will run them, my case is that i want to check if one of
them is true and not both
any idea?
2010 Dec 17
2
Log Filtering Sensitive Data
Hi,
I know how to filter passwords, etc etc by using the below
filter_parameter_logging :password
But if i have params like the below so how do i filter them out.
"order"=>{"card_number"=>"4111111111111160"}
ive tried the following below but it doesnt seem to work
filter_parameter_logging :card_number, :order_card_number, :order
How do people do this
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
2009 Aug 06
13
Redirect after login
Hi,
I''m new to Ruby/RoR so please bare with me!
I''m trying to adapt a ruby setup where someone logs in to a bonjour
service via a web browser. I have the login screen which asks for host
and password. There is only one user per host and i can log in fine.
It''s suppose to redirect me to /list in my browser but
doesn''t. Once i''ve entered the correct
2010 Dec 01
10
How to Redirect from http://mysite.com to https://www.mysite.com on Herok
Hello I''m looking to learn how to redirect all non-www (mysite.com) to
https://www.mysite.com
I tried the following:
class ApplicationController < ActionController::Base
before_filter :check_uri
def check_uri
redirect_to request.protocol + "www." + request.host_with_port +
request.request_uri if !/^www/.match(request.host) if Rails.env ==
2009 Oct 28
1
Authlogic Page View Authentication Help
Hi:
I am a newbie at ROR, and I am grasping my head around Authlogic. I am
having hard time trying to figure out how can I do the following:
in my application controller I have the following helpers:
filter_parameter_logging :password, :password confirmattion
helper_method :all
private
def current_user_session
return @current_user_session if defined?
(@current_user_session)
2008 Jun 30
1
rake aborted! undefined method `time_zone=' for #
Dear
I have uploaded one project on my account on one of the servers. When
I do migrate
the database rake db:migrate
i get this error
rake aborted! undefined method `time_zone='' for #
any idea on how to solve this problem
Thanks
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby on Rails:
2007 May 01
2
Silence logging for a particular action
Anyone know how to silence logging of a particular Rails action?
I have monit setup to ping a "/ping" route and the action just renders
some quick text. The problem is I get:
Processing SiteController#ping (for 127.0.0.1 at 2007-04-30 19:55:46) [GET]
Session ID: 78f1e1aa5c7ddb194565ee79950de618
Parameters: {"action"=>"ping",
2007 Dec 07
2
Pagination using will_paginate
Hi,
I use will_paginate plugin to paginate the records in my view file..
I implement the same in 2 of my modules..
Its working fine in one module where i perform only the basic CRUD
operation.
In the other module i do have search option. This plugin behaves
different for that method..
Normally if one click the page number links the request will be posted
back to the same action or method
2008 Apr 30
7
rescue_from issue with AWS - uninitialized constant
The new rescue_from in edge rails seems to conflict with
ActionWebService, which I need for various other purposes. When I
define, for example (with AWS gem installed):
<b>rescue_from ActionController::RoutingError, :with
=> :page_not_found</b>
I get the exception:
<b>uninitialized constant
ActionWebService::Dispatcher::ActionController::Base</b>
OK, so AWS
2008 Mar 14
3
ActionController <-> ActiveView code access ambiguity
Hi All!
This is not a problem in general but i''ve just missed the point.
If my application has a global state, which i have to use both
throughout ActionController and ActiveView, then, where to place that
state?
E.g. if I do this:
class ApplicationController < ActionController::Base
protected
def authenticated?
!user.nil?
end
end
then I can''t use that from any
2007 Feb 10
3
recognize_path discrepency
hey all - wondering if someone would relive my confusion...
given a model called say Meeting and a route as
"map.resources :meetings"
in the console:
>>r=ActionController::Routing::Routes
>>r.recognize_paths "/meetings"
=>{:action="index",:controller=>"meetings"}
all works as I expect, but if I do
>>r.recognize_paths
2009 Dec 25
18
rescue_from ActionController::RoutingError II
OK ... so I''m not supposed to use it but ...
Why doesn''t rescue_from ActionController::RoutingError work witht he
code from
http://www.rubyplus.org/episodes/20-Extended-RESTful-Authentication-Rails-2-App.html
class ApplicationController < ActionController::Base
helper :all # include all helpers, all the time
# See ActionController::RequestForgeryProtection for details
2009 Apr 06
9
setup method in functional tests and instance variables
I have the following in my functional test file.
class UserControllerTest < ActionController::TestCase
fixtures :users
def setup
@controller = UserController.new
@request = ActionController::TestRequest.new
@response = ActionController::TestResponse.new
@invalid_user = user(:invalid_user)
@valid_user = users(:valid_user)
end
def test_login_success
2009 Aug 28
4
InvalidAuthenticityToken
Hi guys
What does the below line says
ActionController::InvalidAuthenticityToken
(ActionController::InvalidAuthenticityToken):
-e:2:in `load''
-e:2
Please guide me
--
Karthik.k
Mobile - +91-9894991640
2008 Apr 15
4
InvalidAuthenticityToken exception when deleting cookies
Hello,
I''ve been testing my project with some manual tests. One of them
consists of deleting cookies ("clean personal info" in firefox) just
before submit the login form. Then, I get an error.
The error message is: ActionController::InvalidAuthenticityToken in
SessionsController#create
I''m on Rails 2.0.2 with restful_authentication plugin. I''m using
2009 Feb 10
2
rescue_from for NoMethodError
Hi everyone,
I was just trying to catch some exceptions in my app,
for "Record Not Found" I used this
in my application.rb file
rescue_from ActiveRecord::RecordNotFound, :with => :record_not_found
rescue_from ActionController::NoMethodError, :with => :show_error
private
def record_not_found
render :text => "404 Not Found", :status =>