In searching for a solution to a javascript problem, I saw multiple comments about link_to_function
being deprecated in Rails 3. However, I\'ve been able to co
While I am intending to switch everything over to unobtrusive javascript, a good intermediate step (for me), was to replace
link_to_function icon_tag('close.png'), '$(this).parent().hide()', :title => t('actions.close'), :class => 'close'
with the following:
link_to icon_tag('close.png'), '#', :onclick => '$(this).parent().hide()', :title => t('actions.close'), :class => 'close'
Very simple. Hope this helps.