Federico successfully answered Adam Thorsen's question:

I'm getting the following error:

ActionView::TemplateError (wrong number of arguments (0 for 1)) on line #30 of app/views/asked/_no_conversations.rhtml:
27: />
28: <%= update_page_tag do |page|
29: page['question_url_input'].select
30: page['question_url_input'].focus
31: end %>
32:


#{RAILS_ROOT}/app/views/asked/_no_conversations.rhtml:30:in `focus'
#{RAILS_ROOT}/app/views/asked/_no_conversations.rhtml:30:in `__bind_1151578440_587515'
/usr/lib/ruby/gems/1.8/gems/activesupport-1.3.1/lib/active_support/core_ext/object/extending.rb:44:in `instance_exec'
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_view/helpers/prototype_helper.rb:377:in `initialize'
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_view/helpers/prototype_helper.rb:669:in `update_page'
/usr/lib/ruby/gems/1.8/gems/actionpack-1.12.1/lib/action_view/helpers/prototype_helper.rb:676:in `update_page_tag'

How can I fix this problem?

People succeed in answering Adam Thorsen's questions 46% of the time (24 successes in 52 attempts).

Answers by: Federico

Federico's Answer:

Reply by Federico 922 days ago

I seems that focus() expects a parameter, try to replace

page['question_url_input'].focus

with

page.focus('question_url_input')

Reply by Adam Thorsen 922 days ago

Thanks Federico, I'll give that a shot and see if it works.