1
我試圖從rails 2.3到upgade,我發現在rails 2中link_to_remote
應該更改爲link_to
在rails 3中具有:remote => true
屬性。link_to_remote屬性/參數在rails 3
而對於:before, :loading, :failure, :update
但我也有一個像:url, :href, :title
屬性非侵入式JavaScript(UJS)我應該如何改變這種?
這裏是軌道2.3代碼我試圖升級
<%= link_to_remote column.label,
{ :url => sort_params,
:before => "addActiveScaffoldPageToHistory('#{href}', '#{controller_id}')",
:loading => "Element.addClassName('#{column_header_id}','loading');",
:failure => "ActiveScaffold.report_500_response('#{active_scaffold_id}')",
:update => active_scaffold_content_id,
:method => :get },
{ :href => href ,
:title => column.header_info}%>
我已經分析了很多網站和Rails文檔,但一切都沒有指定有關這些屬性的link_to