robbyrussell (owner)

Revisions

gist: 80227 Download_button fork
public
Public Clone URL: git://gist.github.com/80227.git
Embed All Files: show embed
snippet.txt #
1
2
3
4
5
6
7
8
9
10
11
12
<input type="hidden" id="x_something" value="1" />
 
<%= periodically_call_remote :update => 'some shit',
                              :url => {:action => :action_name},
                              :condition => "$('x_something') == '1'",
                              :frequency => 2.0 %>
                              
                              
 
# then...
 
just set the hidden field to 0 or something else when you want it to stop