Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

undefined method html_safe for String #1

Closed
smartinez87 opened this Issue Apr 13, 2010 · 6 comments

Comments

Projects
None yet
4 participants

Error when going to: http://localhost:3000/tolk/locales/en

ActionView::TemplateError (undefined method `html_safe!' for "1":String) on line #39 of vendor/plugins/tolk/app/views/tolk/locales/show.html.erb:
36:
37: <% end %>
38:


39: <%= will_paginate @phrases, :renderer => Tolk::LinkRenderer %>
40:

41: <% else %>
42:

There aren't any missing or updated phrases that need translation.

vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:301:in `page_link_or_span'
vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:261:in `windowed_links'
vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:258:in `each'
vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:258:in `inject'
vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:258:in `windowed_links'
vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:117:in `will_paginate'
vendor/plugins/tolk/app/views/tolk/locales/show.html.erb:39

Rendered rescues/_trace (40.1ms)
Rendered rescues/_request_and_response (0.3ms)
Rendering /home/sebastian/wyeworks/desarrollo/myhistory/vendor/plugins/facebooker/templates/layout.erb (200)

Collaborator

lifo commented Apr 13, 2010

You will need to be on Rails 2.3.

Collaborator

lifo commented Apr 13, 2010

Also, please do make sure you try it with the latest Tolk - http://github.com/dhh/tolk/commit/cce0121202787c7e3c3e92b5a84c5a9f9be0f16e

I am using RAILS_GEM_VERSION = '2.3.2', and just installed the plugin, so it should be the latest version.
Regarding will paginate, I'm using
config.gem 'mislav-will_paginate', :lib => 'will_paginate', :source => http://gems.github.com'

I'm still getting the error on http://localhost:3000/tolk/locales/de/all....and have the commit you mention on the plugin......

ActionView::TemplateError (undefined method `html_safe!' for "1":String) on line #50 of vendor/plugins/tolk/app/views/tolk/locales/all.html.erb:
47:

<%= locale_form.submit "Save changes" %>


48:
49:

50: <%= will_paginate @phrases, :renderer => Tolk::LinkRenderer %>
51:

52: <% end %>
53: <% else %>

vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:301:in `page_link_or_span'
vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:261:in `windowed_links'
vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:258:in `each'
vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:258:in `inject'
vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:258:in `windowed_links'
vendor/gems/mislav-will_paginate-2.3.11/lib/will_paginate/view_helpers.rb:117:in `will_paginate'
vendor/plugins/tolk/app/views/tolk/locales/all.html.erb:50
vendor/plugins/tolk/app/views/tolk/locales/all.html.erb:12

Rendered rescues/_trace (157.1ms)
Rendered rescues/_request_and_response (1.1ms)
Rendering /home/sebastian/wyeworks/desarrollo/myhistory/vendor/plugins/facebooker/templates/layout.erb (200)

Owner

dhh commented Apr 13, 2010

smartinez, you need to be on Rails 2.3.6 with the rails/rails_xss plugin installed.

szimek commented May 12, 2010

Hey, we're thinking about using Tolk, but since Rails 2.3.6 has not been released yet (BTW. any ETA? :)) - do you guys know if it works correctly with 2.3.5 and NZKoz/rails_xss?

This issue was closed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment