Rails 3.1 link_to not showing confirmation or destroying properly

后端 未结 2 745
旧巷少年郎
旧巷少年郎 2021-01-20 01:22

I\'ve been plowing through the chapters at railstutorial.org and been using Rails 3.1.3 because I\'m crazy and/or wanted a challenge. I managed to figure out most version pr

2条回答
  •  无人共我
    2021-01-20 02:11

    So for all of you pulling out your hair for using Rails 3.1, here's the solution.

    <%= javascript_include_tag "application" %>
    

    Using "application" instead of :defaults solves this problem, delete and confirm should work, now get back to coding!

    Special thanks to George Shaw for this answer over on https://stackoverflow.com/a/8350158/1127011 .

    And it case you were wondering, title is for mouseover only.

提交回复
热议问题