Skip to content

Instantly share code, notes, and snippets.

@robbyrussell
Created March 17, 2009 01:44
Show Gist options
  • Save robbyrussell/80227 to your computer and use it in GitHub Desktop.
Save robbyrussell/80227 to your computer and use it in GitHub Desktop.
<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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment