search for: viewhelpers

Displaying 9 results from an estimated 9 matches for "viewhelpers".

Did you mean: view_helpers
2011 Oct 08
1
Rails view spec expectations/matchers
>From looking at the RSpec Rails documentation (https://www.relishapp.com/rspec/rspec-rails/docs/view-specs/view-spec) it seems like rendered is just a string and you can''t really do any assert_select type stuff out of the box. After Googling around, it seems that the RSpec authors decided that if you want that functionality, you should just use Capybara or some such... is that
2010 Jul 23
0
alias_method_chain with i18n
...ello, I was investigating solutions for i18n with will_paginate and I found a possible solution at http://lawrencesong.net/2009/01/enable-i18n-in-will_paginate-plugin/ The author adds to application_helper.rb the following code: ############################################# include WillPaginate::ViewHelpers def will_paginate_with_i18n(collection, options = {}) will_paginate_without_i18n(collection, options.merge(:previous_label => I18n.t(''will_paginate.previous''), :next_label => I18n.t(''will_paginate.next''))) end alias_method_chain :will_paginate, :i18n ##...
2010 May 18
0
ruby-recaptcha seems be broken or has significant limitation
I''ve installed the ruby-recaptcha gem as instructed here: http://bitbucket.org/mml/ruby-recaptcha/wiki/Home Here are the steps that I''ve comleted: 1. installed the gem 2. added config.gem ''ruby-recaptcha'' environment.rb: 4. modified action_controller.rb class ApplicationController < ActionController::Base include ReCaptcha::AppHelper 5. modified
2010 Jul 20
2
uninitialized constant WillPaginate::LinkRenderer
This is becoming painful. Where the file should be? What should be in it? I am running will_paginate 3.0.pre Here is my current code sitting in initializers/ class WillPaginateRenderer < WillPaginate::LinkRenderer def rel_value(page) "nofollow" end end Thanks for your help, -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed
2006 Mar 04
13
Using helpers from controllers ?
There is a solution to use helpers from controllers ? I have an error : |undefined method `content_tag''| class ApplicationController < ActionController::Base def test return content_tag("a","test") end end
2009 Mar 21
2
ApplicationHelper::WillPaginate (NameError)
What wrong? environment.rb require "will_paginate" application_helper.rb include WillPaginate::ViewHelpers def will_paginate_with_i18n(collection, options = {}) will_paginate_without_i18n(collection, options.merge(:previous_label => I18n.t(:previous), :next_label => I18n.t(:next))) end alias_method_chain :will_paginate, :i18n /usr/lib/ruby/gems/1.8/gems/activesupport-2.3.2/lib/active_support/de...
2009 Aug 24
4
will_paginate: pagination links are wrong
I put everything in a pastie to make it a bit more readable: http://pastie.org/593379 This is the gist: Will_paginate doesn''t play quite nice. The first result set is fine, and when I click on one of the paginated links, it returns the following error: Couldn''t find DictatedExam with ID=filter_widget observe_field triggers filter_widget which calls the paginated search.. Which
2006 Feb 19
2
How far can you get without learning Ruby?
This has been my little experiment for the last few weeks. I jumped straight into rails after a few tutorials and have been using "Agile Web Development with Rails" as a reference. I picked up the Ruby syntax from examples which was not hard to do as I know various other languages. I''ve started 3 database driven web apps and all was going really well. Rails is fun and
2006 Feb 24
4
Any way to pass state to a component?
I am trying set up a rails app that utilizes components. I need to be able to pass some state (a bunch of name value pairs) from the Main controller to the component. Is there any way to pass this state info using render_component? Regards -- Posted via http://www.ruby-forum.com/.