I use some code working nicely on Rails 3 but not on Rails 4, I guess it is caused by Turbolinks but I don\'t know much about it, can\'t dig more deep to solve my problem, h
Solved this by moving = javascript_include_tag "application", "data-turbolinks-track" => true from body to head, thanks all your help
= javascript_include_tag "application", "data-turbolinks-track" => true